Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

problem with NetWorkDays function

Hi everybody,

I am trying to calculate the number of working days between 2 dates, so it seems quite simple, but it does not work... I guess it comes from the format of my data, but I tried many things to make it working.

Here is my code. This is an expression I calculate in a chart


=NetWorkDays(Date#(RCVDATE,'YYYYMMDD'),Date#(AMD_DATE))


AMD_DATE is a timestamps, I guess it should work without the Date#() but it does not work. RCVDATE is a number which represents a date in the format YYYYMMDD. My date format is D/MM/YYYY, and the function Date#() is well working on other data.

edit: it seems that Date#(AMD_DATE) returns YYYY-MM-DD hh:mm:ss format while Date#(RCVDATE) returns YYYYMMDD format. I guess I need the same format for both, how can I do this?

Has anyone an idea of why it is not working?

Thank you for your answer

1 Reply
Not applicable
Author

I finally fixed up my problem, I just have to put the full format of AMD_DATE, which was 'YYYY-MM-DD hh:mm:ss'.