Example - Applying filtering to a table | Qlik Cloud Help
Skip to main content Skip to complementary content

Example - Applying filtering to a table

You can add a filtered table to your PixelPerfect report using the PixelPerfect Filter Editor. In this example, you will use the workflow for creating a highly formatted table, and then edit the Filter String property for the band on which you have added the table.

Refer to the example application sources here: Examples - In-application reporting. Upload the application and data files into a space, and then reload the application. You are ready to complete the example.

What you will do

In this example, we create a highly formatted table that is filtered to only show the sales for product types with sales exceeding $5,000,000.00.

Step 1: Create a data binding

  1. Create a new PixelPerfect template.

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

    Field List menu in the PixelPerfect designer

    The 'Field List' menu expanded from the right side panel in the PixelPerfect designer
  3. Hover your cursor over Levels, and then click Plus.

  4. Expand the Sales Tables sheet. Next to Sales by Product Type, click Plus.

    The data binding is created.

Step 2: Create the banded structure

We create a basic structure of bands that will contain the table.

  1. On the design surface, right-click anywhere within the Detail1 band and click Insert BandDetailReport.

    A new DetailReport band is inserted below Detail1.

  2. Right-click the Detail2 band within the Detail Report band you just created. Click Insert BandGroupHeader.

    The band is inserted above the Detail2 band.

Step 3: Bind the content to the data source

  1. Select the outermost DetailReport band in the structure (DetailReport1).

  2. Click the gear icon at the edge of the design surface.

    Clicking the gear icon

    Close-up of the side of the design surface with a band selected, and the gear icon clicked, showing a popup menu for different settings
  3. In the menu, select the Sales by Product Type level as the Data Member.

    Tip noteAlternatively, click Cog wheel at the far right of the designer. Add the Data Member under Detail Report Tasks.
  4. Open the Database icon with plus symbol Field List menu, and expand Levels.

  5. Drag each of the fields within the Sales by Product Type level onto the Detail2 band.

  6. Arrange the field items on the band so they resemble two adjacent rows in a table.

    Tip note

    To align objects precisely with the grid, resize them manually until they are as close to grid lines as possible. Then, right-click each object and select LayoutSize to Grid. You can also open the Cog wheel Properties menu and adjust their size values numerically under LayoutSize.

    For more information, see Arranging content in your PixelPerfect report template.

  7. We need to format the Sales values as currency figures. Click the Sales label, and then click the gear icon that appears next to it.

  8. In the popout menu, click the ellipsis (three dots) menu under Text Format String.

  9. The Format String Editor dialog opens. Choose Currency, and adjust the decimal points. Click OK.

    Configuring number formatting

    The Format String Editor dialog showing the options available for formatting text content
  10. Resize the Detail3 band, shrinking it so that it is only as small as the items in it.

Step 4: Add column headers

Add column headers within the GroupHeader band by dragging objects onto the design surface.

  1. From the toolbox on the left side of the designer, drag two Database icon with plus symbol Label objects (one for each column) onto the GroupHeader1 band.

  2. Arrange the labels at the top of the GroupHeader1 band so that they are the same length as the table row labels.

  3. Double-click each label and insert your own custom fixed text. In this case, you can use the field names.

  4. Customize font as desired. For example, you might want column headers to stand out, so you could make them bold.

  5. Change the band size so that the objects take up the entire band height.

Banded structure for table

Banded structure for the PixelPerfect table

Step 5: Filter the table

  1. Select the DetailReport1 band, and open the Cog wheel Properties menu.

  2. Under Detail Report Tasks, click the three-dot icon for Filter String.

    The Filter Editor opens.

  3. Move your cursor to the right of the And button. Click the plus symbol that appears.

  4. Select Add Condition.

    A condition is created with some default parameters.

  5. Change the Product Type field to Sales by clicking on it and using the drop down menu.

  6. Change the Equals operator to Is greater than.

  7. Select the <enter a value> item, and enter the value 5000000.

  8. PixelPerfect Filter Editor with filter added

    Filter Editor with condition added in the graphical user interface: Sales Is greater than 5000000
  9. Click OK.

Click Save template, and then click Preview report. Download the report and open it to see how it looks.

Report preview showing table with product types that have sales in excess of $5,000,000.00.

Previewed report showing a filtered PixelPerfect table

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!