Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
swiftfahad
Contributor III
Contributor III

Creating date dimensions from variables

hello grus

On my dashboard I am taking to and from dates from user  using calendar and storing those dates in variables

v_fromdate

v_todate

Say after user selection I have a values

v_fromdate: 01-DEC-2016

v_todate : 30-NOV-2017

now is there any way I can set my chart dimensions from 01-Dec-2016 and 31-Dec-2017  in other words how can I map calendar selection from my existing date filed (voucher_Date) already present in table.

I wanna display month wise graph according to user selection

like

Year-monthCollection
2016-DEC1500
2017-JAN1000
--
--
--
--
2017-NOV5000
4 Replies
YoussefBelloum
Champion
Champion

Hi,

you can use your dates variables in a set analysis, like this:

...{<   Date = {">=$(=v_fromdate) <=$(=v_todate)"}   >}...

swiftfahad
Contributor III
Contributor III
Author

wht abt dimension? should i break voucher_date into year-month and select as dimension?

Anil_Babu_Samineni

May be this?

If([Year-month] >= Date($(v_fromdate), 'DD-MMM-YYYY') and [Year-month] <= Date(YearEnd($(v_todate)), 'DD-MMM-YYYY'), Date(Date#([Year-month], 'YYYY-MMM'), 'DD-MMM-YYYY')

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
YoussefBelloum
Champion
Champion

do you use straight/pivot tables or tablebox for this one ?

as soon as you use expressions you can use the calendar dimensions you want..

give it a try