On dashboard side keeps normal just setting the drill through to the target, on target report suppose you have a list report... you will need to add 3 list reports linked to three different queries, on each query
queries:
as you can see one query is only to show when the user selects between, another query when the user selects after and another for before,
FOR BETWEEN query you have to set the filter of this way: cast([Presentation View].[CMPA Data].[Report Period],date) in_range ?Report Period?
FOR BEFORE query you have to set the filter of this way: _add_days (cast([Presentation View].[CMPA Data].[Report Period],date),1) in_range ?Report Period?
FOR AFTER query you have to set the filter of this way: _add_days(cast([Presentation View].[CMPA Data].[Report Period],date),-1) in_range ?Report Period?
finally the magic trick here is based a conditional variable we will filter the section according what the user selected in the dashboard(source)
p_ReportPeriod:
if(ParamDisplayValue('Report Period') is not null) then
(
case
when (substring (ParamDisplayValue('Report Period'),1,1) = 'B' ) then ('Between')
when (substring (ParamDisplayValue('Report Period'),1,1) = 'G') then ('After')
when (substring (ParamDisplayValue('Report Period'),1,1) = 'L') then ('Before')
else ('ALL')
end
)
else
(
'ALL'
)
once the variable is created you will set this variable on each list ex: setting the variable in the lista which is linked to the between selection:
hope this help.
------------------------------
GARY EDUARDO DIAZ PALACIOS
------------------------------
Original Message:
Sent: Thu January 28, 2021 06:30 AM
From: Chandrashekhara Kundadka
Subject: Dashboard Drill Through Passing Dates
Hi,
Myself also looking for details on how to pass how to pass the date range from the Dashboard Filter to Drill through Report (before, Between, after etc). Where there any further enhanced way how to do this on Cognos Analytics Dashboard?
Apologies for picking old thread, but I felt the issue/topic is related.
Regards,
Chandra
------------------------------
Chandrashekhara Kundadka
Original Message:
Sent: Wed April 08, 2020 02:48 PM
From: Smitha Nair
Subject: Dashboard Drill Through Passing Dates
Hi Jeremy,
Could you please suggest how you used in_range function in target report filter. When i am trying dashboard is passing date range as '2020-03-01 , 2020-03-31' as comma separated and not able to get data in target report using in_range filter.
Appreciate your help!
Thanks,
Smitha
------------------------------
Smitha Nair
Original Message:
Sent: Tue December 11, 2018 05:39 PM
From: Jeremy Aude
Subject: Dashboard Drill Through Passing Dates
Solved by using an in_range filter on the report.
------------------------------
Jeremy Aude
Original Message:
Sent: 12-05-2018 09:34 AM
From: Jeremy Aude
Subject: Dashboard Drill Through Passing Dates
Hello,
I am working on a dashboard with a date filter. The dashboard should drill-through to a report while passing the date range as a parameter. It seems the dashboard is not passing through a date range as it's only passing two dates comma separated. Does anyone know how can I accomplish passing a range or a workaround to handle this?
Thanks,
Jeremy
------------------------------
Jeremy Aude
------------------------------
#CognosAnalyticswithWatson