Skip to main content

How to find difference between two dates in Qlik script?

The solution is here

fabs(Date(Field1,'DD/MM/YYYY')) - fabs(Date(Field2,'DD/MM/YYYY'))

For ex:

LOAD
    orderDate,
    desDate,
    delDate,
    fabs(Date(desDate,'DD/MM/YYYY')) - fabs(Date(orderDate,'DD/MM/YYYY')) as orderDespatchGap,
    fabs(Date(delDate,'DD/MM/YYYY')) - fabs(Date(orderDate,'DD/MM/YYYY')) as leadTime,
    fabs(Date(delDate,'DD/MM/YYYY')) - fabs(Date(desDate,'DD/MM/YYYY')) as despatchDeliveryGap
FROM [<DATA LOCATION>]


Popular posts from this blog

The old company comeup with new brand MAXBEN - Logo meaning

I am so happy to design this logo for my friend Suresh Mahalingam to boost his paint business to the next level. The first step in his process is logo design. He had a clear idea about his business, processes, pricing and target audience. I just collect all those information from him and created the logo with some appropriate meanings. Check out the logo here