Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Join two columns

Guys,

I need to join different columns from two tables into a single column.

I have two tables temp1 and temp2. In temp1 "Date" and "sheet_date" in temp2, these two fields are of date values.

I want these two fields to be combined as single field or column. So I have used the below code, but the output was not as I expected.

temp1:

LOAD EmployeeID,

      Date,

     Date(Date,'MM/DD/YYYY') as Date

FROM

[..\RM_Extracted_QVD\EXT_presentEmpInfo000.qvd]

(qvd);

Join

temp2:

LOAD ProjectID,

     sheet_date,

     Date(sheet_date,'MM/DD/YYYY') as Date,

     ProjTaskID,

     worked_hours,

     Billable,

     EmployeeID,

     UserName as FullName

FROM

[..\RM_Extracted_QVD\EXT_ResourceTimesheet.qvd]

(qvd);

Output which I got:

Screenshot_1.png

I have combined Date and sheet_date into a single field as "Date". But in the above screenshot, multiple values repeated for the same date as you can see.

Output which I expect:

Screenshot_2.png

Please suggest some other ways to achieve this.

4 Replies
PrashantSangle

Hi,

In temp1 try

Date(floor(Date),'MM/DD/YYYY') as Date


and In temp2


Date(floor(sheet_date),'MM/DD/YYYY') as Date


Regards,

Prashant



Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
ahaahaaha
Partner - Master
Partner - Master

May be use

LOAD Distinct

....

qlikview979
Specialist
Specialist

Can you please share the qvd's

Anil_Babu_Samineni

May be use DISTINCT keyword

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful