Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

Not applicable

difference in date of the sap format date

Hi Guys,

Please help me......

i need to get a difference of two dates from SAP Data. columns are posting date and document date.

the condition should be if posting date - document date is <= 5 it is not violated if more than 5 its violated.

the date format is like this DD.MM.YYYY

1 Solution

Accepted Solutions
Not applicable

Re: difference in date of the sap format date

Hi,

You can try something like this:

=if(interval((Date(PostingDate)-Date(DocumentDate)),'DD')<=5,'Not Violated','Violated')

Hope this helps.

Regards,

-Khaled.

4 Replies
vikasgupta
Contributor

Re: difference in date of the sap format date

Hi

Try to use this format

if((OrdDate-OmDelDt) <= 0, (OrdDate-OmDelDt),(OrdDate-OmDelDt)) as Ontime

Thanks

Vikas Gupta

vikasgupta
Contributor

Re: difference in date of the sap format date

Hi

If you wants to change the date format use this expression :

Date(OmExpDelDt,'DD/MM/YYYY') AS OmExpDelDt

and the syntax format of if is following :

if(condition , then , else)

Thanks

Vikas gupta

Not applicable

Re: difference in date of the sap format date

Hi,

You can try something like this:

=if(interval((Date(PostingDate)-Date(DocumentDate)),'DD')<=5,'Not Violated','Violated')

Hope this helps.

Regards,

-Khaled.

nagaiank
Valued Contributor III

Re: difference in date of the sap format date

You may try

=if(Date#(PostingDate,'DD.MM.YYYY')-Date#(DocumentDate,'DD.MM.YYYY')<=5,'Not Violated','Violated')