Dears
I'm new to SSAS World, and am trying to enhance report performance by using Analysis services MDX Query
I know that SQL differs from MDX, but I need hints if I can use parameters inside Named Query That I need to do calculations for each record
Check this>> to calculate NO of Days Off
OUTER APPLY ( SELECT SUM([dbo].[DurationWithoutWeekend](CASE
WHEN @datefrom >= TCCDays.StartTime
THEN @datefrom
ELSE TCCDays.StartTime
END,
CASE
WHEN @dateto >= TCCDays.EndTime
THEN TCCDays.EndTime
ELSE @dateto
END)) AS DAYSOff
FROM Tfs_DefaultCollection.dbo.tbl_TeamConfigurationCapacityDaysOffRange TCCDays
WHERE IM.localId = TCCDays.TeamMemberId
AND ( TCCDays.EndTime >= @datefrom
OR TCCDays.EndTime IS NULL
)
Thanks in advance
Check these out, try your luck..
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.