Skip to main content Skip to complementary content

Handling Qlik application data in PixelPerfect reports

This help topic provides guidelines for formatting certain types of Qlik analytics data in your PixelPerfect report.

Handling dates and dual values

Dates and dual values are supported in PixelPerfect reports—for example, those used in autocalendars.

For example, the My_Date_Field field in this script excerpt:

[autoCalendar]:
  DECLARE FIELD DEFINITION Tagged ('$date')
FIELDS
  Dual(Year($1), YearStart($1)) AS [Year] Tagged ('$axis', '$year'),
...
DERIVE FIELDS FROM FIELD [My_Date_Field] USING [autoCalendar] ;		
 

In PixelPerfect reports, dual and date values are shown by default as serial numbers. To display them as dates, for example, you need to format them as dates in the template using the PixelPerfect designer.

  1. Open the Database icon with plus symbol Field List menu available from the right-side panel in the designer.

  2. Under Levels, expand or create the item that you want to format as a date.

  3. Hover your cursor over the item and click the Add calculated field icon.

    Creating a calculated field

    Adding a calculated field for a level in the PixelPerfect designer.
  4. On the new calculated field, click the Edit icon.

  5. Optionally, add a Name to change it from the default.

  6. Next to Expression, click More.

  7. In the Expression Editor, paste the following expression, replacing my_date_field with the name of your date field:

    AddDays( #1899-12-30#, [my_date_field] )
  8. Click OK.

  9. Add the item to the report design surface.

    Working with levels

  10. Set the date format you want to use in the Format String Editor. Do the following:

    1. On the design surface, select the item.

    2. Click the three-dot icon next to the item, and then click the gear icon.

    3. Click More under Text Format String.

    4. Select the date format you want to use, and click OK.

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – please let us know!