Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
mikevmalta
Partner - Contributor III
Partner - Contributor III

Duplicate data when linking tables

Hi,

I have a project table where one field is a date, and I want to link / join it with a master calendar. Therefore, when I select a year or month, records from this table should be selected.

Having created a master calendar table and linked it with the project table (by the date field), Qlikview is considering the records as separate. For example, I am having the following:

Date               ProjectName

02/09/2013     'Project1'

02/09/2013     -

03/09/2013     -

04/09/2013     -

I would like to have only one record for the date '02/09/2013' (in this case), or more than one only if there are more project names on the same date. Furthermore, when I select the year '2013', only the record with no project name is being selected.

I tried to do a left join with the project table but still no success. I also tried to format the date field from both the project table and the master calendar table as Date, Num or text, but still no success.

Do you have any idea why this is happening please?

Thanks in advance!

1 Solution

Accepted Solutions
mikevmalta
Partner - Contributor III
Partner - Contributor III
Author

Hi Guys,

Thanks a lot for your replies!

Found the source and solution to the problem!! I am now retrieving the dates for the projects without the time, and it's removing the duplicate records succesfully.

Thanks again for your contribution!

View solution in original post

6 Replies
Not applicable

Hi Mike,

It would be easier for me to help if you could upload your QVW for us to have a look at.

Thanks,

Byron

er_mohit
Master II
Master II

use distinct function

like

load distinct

fieldA,

fieldB,

....................

from table;

jvitantonio
Luminary Alumni
Luminary Alumni

Hi , please check the file attached. If this simple example still doesn't work, then it's because you might have data in your Project table with empy Project Names.

mikevmalta
Partner - Contributor III
Partner - Contributor III
Author

Hi Guys,

Thanks a lot for your replies!

Found the source and solution to the problem!! I am now retrieving the dates for the projects without the time, and it's removing the duplicate records succesfully.

Thanks again for your contribution!

Not applicable

What would be a solution if you did not have a Date field?  For example.... I only have a Date/Time field, and no other option.

mikevmalta
Partner - Contributor III
Partner - Contributor III
Author

Hi Paul,

you can create another field, which would be the date version of the Date/Time field.

MakeDate(Year(yourdatetime),Month(yourdatetime),Day(yourdatetime))


Hope this answers your question.