Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

rekha_jv
New Contributor III

Date function - Variable

Hello,

I am using the below expression directly in a chart  its working but if I try to create a variable using the same expression its giving the expected result. Could any one help me?

=Date(max(Close_Week_End_Date),'YYYY-MM-DD')

Thank you in advance.

Regards,

Rekha J. V.

1 Solution

Accepted Solutions
OmarBenSalem
Esteemed Contributor

Re: Date function - Variable

try to call it as follow :

=$(vCurrentWeekEndDate)

or

='$(vCurrentWeekEndDate)'

7 Replies
OmarBenSalem
Esteemed Contributor

Re: Date function - Variable

can u please develop more?

1) what chart u're using this expression in? which dimension?

a screen shot maybe?

2) when u use a variable? how are u using it?

how are u calling it?

screen shot maybe?

rekha_jv
New Contributor III

Re: Date function - Variable

Hello Omar,

This is how I am using in KPI

Created a variable using same:

Now if I use the variable in KPI it will not show up the date

Nor its showing when I use in Set expression

Regards

Rekha

OmarBenSalem
Esteemed Contributor

Re: Date function - Variable

try to call it as follow :

=$(vCurrentWeekEndDate)

or

='$(vCurrentWeekEndDate)'

Re: Date function - Variable

How you define in variable?

LET Variable = =Date(max(Close_Week_End_Date),'YYYY-MM-DD');

Life is so rich, and we need to respect to the life !!!
rekha_jv
New Contributor III

Re: Date function - Variable

Hello Omar,

='$(vCurrentWeekEndDate)' returns the appropriate  date.

Thank you,

Rekha J. V.

OmarBenSalem
Esteemed Contributor

Re: Date function - Variable

Good, but u should have marked my answer as correct

rekha_jv
New Contributor III

Re: Date function - Variable

Sorry by mistake. Marked your answer as correct. :-)

Thanks once again.

Community Browser