Daniel Mejia
06/10/2022, 4:06 PMone request
?Daniel Mejia
06/10/2022, 4:07 PM<cfquery name="defaultorgqry" datasource="mydbdatasource"
cachedafter="#cachedate#"
result="defaultorgresult"
select BillingCategory from mydatabase.dbo.EM
where employee = <cfqueryparam value="#employeeid#" cfsqltype="cf_sql_integer" />
</cfquery>
asishd
06/10/2022, 4:19 PMasishd
06/10/2022, 4:19 PMDaniel Mejia
06/10/2022, 4:19 PMasishd
06/10/2022, 4:21 PMDaniel Mejia
06/10/2022, 4:21 PMDaniel Mejia
06/10/2022, 4:21 PMasishd
06/10/2022, 4:23 PMDaniel Mejia
06/10/2022, 4:27 PMDaniel Mejia
06/10/2022, 4:27 PMasishd
06/10/2022, 4:27 PMasishd
06/10/2022, 4:32 PMasishd
06/10/2022, 4:32 PMDaniel Mejia
06/10/2022, 4:33 PMasishd
06/10/2022, 4:35 PMDaniel Mejia
06/10/2022, 4:35 PMasishd
06/10/2022, 4:36 PMDaniel Mejia
06/10/2022, 4:36 PMdanmurphy
06/10/2022, 4:43 PMDaniel Mejia
06/10/2022, 4:43 PMDaniel Mejia
06/10/2022, 4:43 PMDaniel Mejia
06/10/2022, 4:44 PMdanmurphy
06/10/2022, 4:44 PMdanmurphy
06/10/2022, 4:44 PMDaniel Mejia
06/10/2022, 4:50 PMdanmurphy
06/10/2022, 4:51 PMDaniel Mejia
06/10/2022, 4:59 PMdanmurphy
06/10/2022, 5:00 PMdanmurphy
06/10/2022, 5:00 PMdanmurphy
06/10/2022, 5:00 PMDaniel Mejia
06/10/2022, 5:01 PMDaniel Mejia
06/10/2022, 5:01 PMDaniel Mejia
06/10/2022, 5:02 PMdanmurphy
06/10/2022, 5:02 PMDaniel Mejia
06/10/2022, 5:03 PMDaniel Mejia
06/10/2022, 5:06 PMDaniel Mejia
06/10/2022, 6:07 PM// DEFAULT LABOR CATEGORY PER EMPLOYEE *********************
TS_LABORCATEGORY_REGION = 'ts_entry_laborcategory';
// IF url param 'tscachebust=true' clear all cache results for TS_LABORCATEGORY_REGION
if( structKeyExists(url,'tscachebust') and url.tscachebust == 'true'){
// IF region exists then remove it and all its cached results
if( cacheRegionExists( TS_LABORCATEGORY_REGION ) ){
cacheRegionRemove( TS_LABORCATEGORY_REGION );
}
}
// create region, does not throw error is it already exists
cacheRegionNew(region= TS_LABORCATEGORY_REGION ,throwOnError=false);
// Get user's default labor category
// query for each employee will cache for 1 day
defaultorgqry = queryExecute(
'select BillingCategory from mydatabase.dbo.EM where employee = :employeeid',
{employeeid: theEmpN},
{
datasource='mydbdatasource',
cachedwithin = createTimespan(1,0,0,0),
cacheRegion = TS_LABORCATEGORY_REGION,
cacheid = 'id_'&theEmpN,
result='tslcresult'
}
);
zackster
06/10/2022, 6:12 PM