Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Not applicable

reasons for duplicate rows

Hi, why are there duplicate rows? I concatenated tables from different sources and 'itemnum' is primary key. The itemnum appears in all the tables and has data for all columns but still duplicates, for example, it has data for all the columns from one table but is null for the other columns in other tables. So there is duplicate like below:

itemnumsitenamebalanceclasscodeGroup
1009AD-B--
1009--45-FGH

How can I combine everything to one row (distinct itemnum)?

itemnumsitenamebalanceclasscodeGroup
1009AD45BFGH

Thanks.

23 Replies
anbu1984
Honored Contributor III

Re: reasons for duplicate rows

Try join instead of concatenation

jebamalai
Valued Contributor

Re: reasons for duplicate rows

can you pls share the datamodel picture?

MVP
MVP

Re: reasons for duplicate rows

Hi

You will need to join rather than concatenate to get them on the same row. Post more details of your data and script for more detailed help on how to do so.

HTH

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Not applicable

Re: reasons for duplicate rows

Oh yes, sorry I meant join. I used 'outer join'.

Not applicable

Re: reasons for duplicate rows

I have used 'outer join'.

Not applicable

Re: reasons for duplicate rows

Is there any other way for you to help me? Because I can't post the data...so sorry.

Not applicable

Re: reasons for duplicate rows

Sorry, what is datamodel picture?

manojkulkarni
Valued Contributor II

Re: reasons for duplicate rows

concatenate will always add separate row, but join on primary key can help you to remove duplicate

MVP
MVP

Re: reasons for duplicate rows

There is something wrong with your join. To get help, you will need to post your load script and some more details of your data. Best solution is to upload your model here.

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Community Browser