Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
soniasweety
Master
Master

How it works?

Hi all,

how below expression works? can anyone explain?

Num(if(month(today())>=2,date('06/02/'&year(today()),'dd/mm/yyyy'),date('06/02/'&year(today())-1,'dd/mm/yyyy')))

Thanks

Sony

12 Replies
stabben23
Partner - Master
Partner - Master

Theoretical it will gives you a numeric value of a hardcoded date.

if this month if greater or Equal With february it gives you 06/02/2017, if not 06/02/2016.

Anil_Babu_Samineni

I believe this won't effect. It may show - because Month(Today()) always return String and String never resemblance with Number. 

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
soniasweety
Master
Master
Author

yes I am getting null

but I want to get month end from that

stabben23
Partner - Master
Partner - Master

Where do you want it, in a textobject? and what do you want to see, explain the Logic.

Anil_Babu_Samineni

To clarify, This will work. But not really know for Which month you are going to have MonthEnd?

=if(Num(Month(today()))>=2,Date(MakeDate(year(today()), 02, 06),'DD/MM/YYYY'),Date(MakeDate(year(today())-1, 02, 06),'DD/MM/YYYY'))

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
tresesco
MVP
MVP

Date() here might not be required that way. Could you explain what exactly you are trying to do? May be explain in plain English. I guess much simpler solution would be there.

soniasweety
Master
Master
Author

its giving me result like below

0.00012394 something

Anil_Babu_Samineni

Never give like that

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
soniasweety
Master
Master
Author

I want to use this as variable

that value should be a  monthend