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

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Issues with Date Fields

Hi Everyone,

I have 3 tables and in each of them I have a date field.

I  have defined in each of my table days, weeks and months thanks to the functions ;

Table A:

DateA,

Day(DateA) as Day,

Week(DateA) as Week

Month(DateA) as Month

Table B:

DateB,

Day(DateB) as Day,

Week(DateB) as Week

Month(DateB) as Month

Table C:

DateC,

Day(DateC) as Day,

Week(DateC) as Week

Month(DateC) as Month

The problem is that this lead to the creation of synthetic keys because of the shared columns of each table (Day,week, month).
Do You know any way to join those 3 fields in all my tables without creating synthetic keys ?

Thank you very much

Alexandre

4 Replies
swuehl
MVP
MVP

You need to decide if you want to link these tables by Date at all or not or maybe concatenate all dates in a common date field. It's mostly a decision how you want to analyze your data.

See also:

Canonical Date

Not applicable
Author

I want all the date fields to be linked meaning that if I select a day in a listbox it will select all the entries related to day(DateA) day(daeb) and Day(datec)

swuehl
MVP
MVP

You could link your three tables by a Date key:

Table A:

DateA as DateKey,

DateA

Table B:

DateB as DateKey,

DateB

Table C:

DateC as DateKey,

DateC

and create a single master calendar for DateKey:

Calendar:

DateKey,

Date,

Day(Date) as Day,

Week(Date) as Week,

Month(Date) as Month

The Master Calendar

qlikviewwizard
Master II
Master II

Hi Alexandre-Bernard

Use Concatenate between these three tables. Hope this will help you.

Table A:

DateA,

Day(DateA) as Day,

Week(DateA) as Week,

Month(DateA) as Month;

Concatenate (Table A)

Table B:

DateB,

Day(DateB) as Day,

Week(DateB) as Week,

Month(DateB) as Month;

Concatenate (Table A)

Table C:

DateC,

Day(DateC) as Day,

Week(DateC) as Week,

Month(DateC) as Month;