Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
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!
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!
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
use distinct function
like
load distinct
fieldA,
fieldB,
....................
from table;
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.
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!
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.
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.