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

Line chart dimension keep showing time instead of month

Hi Guys,

My data model is very simple.

Just one table and 3 columns. It looks something like this

Month YearProduct NameTotal Sales
01-05-2017Milk500
01-05-2017Bread600
01-06-2017Milk700
01-06-2017Bread900
01-07-2017Milk300
01-07-2017Bread500

(Date Format: DD-MM-YYYY)

When I create a line chart in qlik sense and select [Month Year] as dimension.. then it automatically converts it into  YYYY-MM-DD HH:MM:SS


line chart.png

How to ensure that the dimension would only show as month year (MMM-YY) ?

I have tried putting dimension as =Date([Month Year],'MMM-YY') but still does not work

1 Solution

Accepted Solutions
ishanbhatt
Creator II
Creator II

Hi Lokesh,

Please check the X-axis Continuous option.

Put Continuous option in Auto mode.

You will find this option under

Appearance -> X-axis.


Ishan

View solution in original post

3 Replies
kenphamvn
Creator III
Creator III

Hi

Try this

Date(Date#([Month Year],'DD-MM-YYYY'),'MMM-YY')

ishanbhatt
Creator II
Creator II

Hi Lokesh,

Please check the X-axis Continuous option.

Put Continuous option in Auto mode.

You will find this option under

Appearance -> X-axis.


Ishan

ishanbhatt
Creator II
Creator II

Hi Lokesh,

Try this in script,

Date(Floor(Num(Date)),'MMM-YY') as [Month Year]


you can also use ceil instead of Floor based on your requirement.

Ishan