Going back to
Say you have something like this
niku.prj_blb_slices.slice_date > dateadd(m,-1,(getdate()))
for each TSV column.
If you wanted days instead of the hours which is unit in the slices you would have to use the conversion factor.
The conversion factor used by the system is the the hours_per_day of the standard calendar, which can be changed any time. If you wanted to do the conversion with what ever factor is current you would have to query for it.
(Select hours_per_day from prcalendar where prid = (Select prcalendarid from prsite)
If you have multiple TSV how would run the query just once and use the results for converting multiple columns?
AND (WHERE@PARAM:USER_DEF:FLOAT:CFACTOR@ = (Select hours_per_day from prcalendar where prid = (Select prcalendarid from prsite))
and then in the query
isnull(sum(niku.prj_blb_slices.slice),0) / CFACTOR
work or would it have to be something else?