Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

fvalente
New Contributor II

Straight table removes duplicate

Hi community I am newbie in Sense,

I am joining two qvd files with an inner join and I am then creating a table object with the result data.

The problem I am running into is that the table is removing duplicates. Is there a way I can keep it.

All "include null values" boxes have been ticked along with "Include zero values" in the data handling section.

I have spotted this with a count column on a variable I am interested in, as per below, the variable "Position"= 0 has a count of 19 but if I remove the count column I do only have one row showing 0 in the table.

table_no_duplicates.png

Is there something that I am missing, which removes the duplicates or is it an auto function?

Thank you in advance

1 Solution

Accepted Solutions
dwforest
Valued Contributor

Re: Straight table removes duplicate

If the count is being done in the chart and not the script, there are duplicate rows in data, but there is another field not shown in the grid that is making them unique. Standard Qlik behavior is to show only unique rows of data in a table.

Example, master calendar: if you only have Month will only show 12 rows, added day will show 365(6) rows. Number of rows in the underlying table is unchanged.

6 Replies
ogster1974
Honored Contributor II

Re: Straight table removes duplicate

Include a field in your load that identifies the source table then you wont remove records that match in the two sources.

Khan_Mohammed
Honored Contributor II

Re: Straight table removes duplicate

As in add a Key field if you've. Simply joining the fields will not match.

Maybe try 'Outer Join' ??

This keeps all the values inside the field

dwforest
Valued Contributor

Re: Straight table removes duplicate

If the count is being done in the chart and not the script, there are duplicate rows in data, but there is another field not shown in the grid that is making them unique. Standard Qlik behavior is to show only unique rows of data in a table.

Example, master calendar: if you only have Month will only show 12 rows, added day will show 365(6) rows. Number of rows in the underlying table is unchanged.

tinaco110
Contributor III

Re: Straight table removes duplicate

Hi Francesco,

That is Qlik Sense standard behaviour, if duplicated records have a meaning, I suggest introducing a column to avoid the behaviour, a column containining a RANDOM value may be enough, just try RND().

HTH

Re: Straight table removes duplicate

This is the intentionally default-behaviour of qlik-objects. There are not many use-cases where you really need to display each single-record, for example by checking the data-quality. For this cases you could add a rowno() or recno() within the load-statement and displaying then this field within the table, too and if you are sure that everything is like it should you should remove it again from the scriptand the table.

- Marcus

fvalente
New Contributor II

Re: Straight table removes duplicate

Thank you all guys for the feedback much appreciated.

I will make sure to add a count for each row and then drop it to make sure that the data is correct.

Thanks for the support

/F

Community Browser