Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Discover how organizations are unlocking new revenue streams: Watch here
cancel
Showing results for 
Search instead for 
Did you mean: 
jeckstein
Partner - Creator
Partner - Creator

Create table of Qlik data model Table Names and Field Names

I want to create a summary table that shows me stats from a data model I create. I want a piece of code to place at the end of my script editor that creates this summary table. This table must be Qualified so it does not interfere with the existing data model

In the script editor I want to create a table that follows this logic.

  • column 1= table name
  • column 2=field names
  • column 3= count (# of rows)
  • column 4= count (distinct( # of rows)

Theses 4 columns are defined as follows

  • field name= the field name for each specific field in my data model
  • table name= the table name which the field is from
  • column 3= count the number of rows for this field in this table
  • column 4= count the number of distinct values for this field in this table

Please let me know if you have any ideas

4 Replies
sumitjadhav
Creator II
Creator II

Hi James,

Follow the below steps :

-->>First goto your Sheet Properties

-->>Goto Fields Tab and then,

Tick the checkbox to show System Fields as Below,

sytemfields.JPG

-->Now ,Add the Required System Fields and Create a table box as below,

fieldop.JPG

Hope This was Helpful.

Thanks & Regards,

Sumit Jadhav.

avinashelite

This tables are generated by default , full the instruction as Sumit mentioned

jonathandienst
Partner - Champion III
Partner - Champion III

You can get a starting point for the front end by selecting New Sheet Object from the Object menu in QV desktop. Select System table from the bottom of the list. This is a pivot table of the tables and fields using the $Tables and $Field.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
jeckstein
Partner - Creator
Partner - Creator
Author

Is there any way to get a distinct field count?