Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I'm trying to load data about mushrooms picking from a table where the "Date" field, mentions date+hour of picking.
I've created a new Dimension for date, using:
DATE(MAKEDATE(1988) + UDATE/1440,'DD/MM/YYYY') as Date,
But the output us several lines for each date (the same amount of lines as if I leave the hour)
How can I consolidate all the lines for certain date to only one line?
Thanks a lot in advance
I am happy to update that I found the solution from a friend.
the solution is by using the function Datestart(), or to be more specific:
DATE(MAKEDATE(1988) + daystart(UDATE/1440),'DD/MM/YYYY') as Date,
hi
if you want to convert seconds to date use this
DATE(MAKEDATE(1988) + UDATE/86400,'DD/MM/YYYY') as Date,
Thanks for your prompt reply.
I tried this but it converted all the dates to the year 1988 and left all the multiple lines
can you provide sample data with output?
Sure
Here is an example (Please ignore the Hebrew):
This is the data in the Priority (the source) with the date and the hour:
And here is the date from the Qlik:
The same 12 lines and the same total
I would like to consolidate them by the date to only one line per date
In the first snapshot there only 10 lines appears out of the 12 lines
@Ishragil did you try below
timestamp(MAKEDATE(1988) + UDATE/1440) as Date,
Tried that, but still the same output:
Hi, taht's beacuse each date is a different value because each one has a different time value, if want to keep only one value for each date you can use floor() to remove the time:
DATE(Floor(MAKEDATE(1988) + UDATE/1440),'DD/MM/YYYY')
I did that:
and the result is still multiple lines, but some lines are missing (in the source there are 12 lines with 1163 Boxes):