Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!

Qlik NPrinting PixelPerfect Charts with a Date and Time field on X axes

No ratings
cancel
Showing results for 
Search instead for 
Did you mean: 
Ruggero_Piccoli
Support
Support

Qlik NPrinting PixelPerfect Charts with a Date and Time field on X axes

Last Update:

Apr 19, 2022 5:19:27 AM

Updated By:

Sonja_Bauernfeind

Created date:

Mar 7, 2019 8:51:16 AM

PixelPerfect native charts have some useful features in case you are using a Date and Time dimension for example in X-axes.

 

Environment:

Qlik NPrinting 

 

We will use a QlikView Straight Table object with sales by day.

010.png

 

  1. Create a new PixelPerfect report, add the straight table object in the Tables node and a new native chart as usual.

    020.png

  2. Select a Line Chart, keep only a series of data and go to Data -> Series Binding tab. In the Argument scale type select Date Time and in the Argument select the field of the straight table that contains the date. Using DateTime data scale means that data provided for the series points will be treated as DateTime values and will be shown on the Axis as DateTime values (e.g., January, 2019).
  3. In the Value select the Sales field.

    030.png

  4. Go to the Axes tab and open the Scale Options on the right side tabs. Select Sale mode Continuous, it means that data aggregation is disabled. The original table has sales by day so we will get a chart with a value for each day.

    Automatic date-time scale mode, meaning that data is automatically aggregated according to the chosen aggregate function.  Manual date-time scale mode, meaning that you can manually choose the aggregate function using the aggregate function and measure unit properties. I suggest to test also these options to familiarize with them.

    040.png

  5. Hide the Point Labels, the Legend and the Marker in the Series View. Run a report preview.

    050.png

  6. If you want to see the x axes grid by month, remove the auto grid option and set grid alignment to month.

    060.png

  7. Run a preview.

    070.png

  8. To remove the secondary tickmarks, open Axes -> Elements -> Tickmarks and uncheck the Visible flag in the Minor tickmarks area.

    080.png

  9. Run a preview.

    090.png

  10. Then to change how date are displayed open Axes -> Labels -> Auto than manually insert in the pattern the string {A:MMMM yyyy}. It means argument in the format of first letters of the month followed by the year with four letters. You can also use the format list.

    100.png

  11. Run a preview.

    110.png

  12. To test the aggregation function go back to the scale options tab and set scale mode to manual, aggregate function to sum and measure unit on month.

    120.png

  13. Run a preview.

    130.png

 

Labels (1)
Comments
gargi_bardhan
Creator
Creator

Thank you so much Ruggero !

This post looks its gonna save me 🙂

I am on my way to try the ways you suggested and glad that it had the option not only of 'Continuous' but many.

Will update once resolved.

Great post !! Its really helpful.

Thanks,

Gargi

 

gargi_bardhan
Creator
Creator

Hi Ruggero,

I have one more doubt.

The pdf preview of pixelperfect chart not coming as expected. 

ActualActualReport getting generated in this formatReport getting generated in this format            Any suggestion where to change the setting?

Thanks,

Gargi 

Ruggero_Piccoli
Support
Support

Hi,

You can remove the markers from the Series View tab and select Markers on the right.

I suggest you to follow all the chart wizard steps and explore the options to have an overview of what you can do.

Best Regards,

Ruggero

gargi_bardhan
Creator
Creator

Got it, Need to use Swift Plot chart type, I was using Line chart type.

Thanks,

Gargi

Lech_Miszkiewicz
Partner Ambassador/MVP
Partner Ambassador/MVP

that's what i am talking about - well done 🙂

DiM
Contributor II
Contributor II

Hi Ruggero,

really helpful post, thank you!

But I have one question: What is the condition that I can use the argument scale type "date time"?

I have a calculated dimension in QV straight table which returns date format:  =Date(if(Year(Cal.Date)=Year(Today()),AddYears(Cal.Date,-1),Cal.Date))

With this,  it is only possible to use "Qualitative", but why?

Best regards,

Diana

Ruggero_Piccoli
Support
Support

Hi,

I did some tests on my installation and the only solution I found is to add a new calculated field in the reload script created with the formula =Date(if(Year(Cal.Date)=Year(Today()),AddYears(Cal.Date,-1),Cal.Date)). Then add it into the chart, save the QVW and refresh the connection cache.

Best Regards,

Ruggero

DiM
Contributor II
Contributor II

Your suggestion did the job an now my line chart looks exactly as I wished.

Thank you very much!

Contributors
Version history
Last update:
‎2022-04-19 05:19 AM
Updated by: