Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Displaying graph dimension date in another format

I have a graph similar to the image below:

Gr.png

It's just a Date as a dimension and a sum of orders on that date as an expression. This is perfect, but is there anyway I can have the dimension labels display as something else? The graph will only show the past 7 days and I'd like it to have the day name so 'Thursday, Wednesday' etc. Is there somewhere I can do that? I tried a custom dimension but it didn't work out too well for me.

1 Solution

Accepted Solutions
Gysbert_Wassenaar

You can use date(MyDate , 'WWWW') to display the long day names. If you need different names than your systems default use the LongDayNames variable in the script:

SET LongDayNames='Monday;Tuesday;Wednesday;Thursday;Friday;Saterday;Sunday';

See attached example.


talk is cheap, supply exceeds demand

View solution in original post

6 Replies
SunilChauhan
Champion
Champion

Try This

weekDay(Datefield)

hope this helps

Sunil Chauhan
Not applicable
Author

Where would I try that? If I add it to the dimensions it ruins my graph?

Aurelien_Martinez
Partner - Specialist II
Partner - Specialist II

Hi,

You can add fields on your model.

Like :

Calendar:

LOAD

Date,

Month(Date) as Month,

WeekDay(Date) as WeekDay

[...]

Best,

Aurélien

Help users find answers! Don't forget to mark a solution that worked for you!
SunilChauhan
Champion
Champion

in dimension or in Script;

see the csript example below

see the attched sample file

Sunil Chauhan
Gysbert_Wassenaar

You can use date(MyDate , 'WWWW') to display the long day names. If you need different names than your systems default use the LongDayNames variable in the script:

SET LongDayNames='Monday;Tuesday;Wednesday;Thursday;Friday;Saterday;Sunday';

See attached example.


talk is cheap, supply exceeds demand
Not applicable
Author

Thanks, this is what I needed.