Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a date field in this format "01/04/2023 00:01:21" . I want list boxes with unique values like Jan-23, feb -23 etc. I tried using this expression "Date(floor(Timestamp#(REQTIME,'DD/MM/YYYY HH:MM:SS')),'MMM/YYYY')" in both script and list box in qlikview but it gave values like "Jan-23, Jan 23, Feb-23, feb 23 ' etc.
request a solution in script or chart or list box....
Thanks in advance
Niranjana
Try with:
Date(MonthStart(Timestamp#(REQTIME,'DD/MM/YYYY HH:MM:SS')),'MMM/YYYY')
Try with:
Date(MonthStart(Timestamp#(REQTIME,'DD/MM/YYYY HH:MM:SS')),'MMM/YYYY')
Modify your script expression slightly. Use the MonthName function to get the month name in three characters (e.g., "Jan") and concatenate it with the year. Here's how you can adjust your script:
MonthName(Month(Timestamp#(REQTIME, 'DD/MM/YYYY HH:MM:SS')), 'MMM') & '-' & Year(Timestamp#(REQTIME, 'DD/MM/YYYY HH:MM:SS')) as MonthYear
Hi ,Thanks for your reply. Your expression works. But I used another format : MonthName(Date(Floor(TimeStamp#(REQTIME, 'DD/MM/YYYY h:mm:ss')), 'DD/MM/YYYY'))
This also worked.