Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Write Table now available in Qlik Cloud Analytics: Read Blog
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Days from current day

Hi

I have a date called INVOICE_DATE.

I want to in script to do the following :

a)  If INVOICE_DATE is not within the 30 days ( from today's date ) then INVOICE_PASS

B) if INVOICE_DATE is within 30 days (from today) then INVOICE_OK

c) if INVOICE_DATE is in the past ( ie yesterday and beyond ) then INVOICE_EXPIRED

1 Reply
rahulpawarb
Specialist III
Specialist III

Hello Shibli,

Considering above requirements, you can compose below fields:

If(Today()-INVOICE_DATE>30, 'INVOICE_PASS', 'INVOICE_OK') AS Status,

If(Today()-INVOICE_DATE>0, 'INVOICE_EXPIRED', 'INVOICE_NOT_EXPIRED') AS IsInvoice_Expired

Regards!

Rahul