Forum

Trying to Unpivot T...
 
Notifications
Clear all

Trying to Unpivot Two Columns

2 Posts
2 Users
0 Reactions
130 Views
(@mjanecek)
Posts: 4
Active Member
Topic starter
 

I have a table of 5 columns, ticket, log_user, log_time,log_user2,Log_time 2(start attached).  I want to have one table of three columns: ticket, log_user and log_time.

I created 2 duplicate copies of the above query. I grouped the first by ticket and log_user, and aggregated it by log_time(two attached).  I grouped the second by ticket and log_user2, and aggregated it by log_time2(three attached).

 

I attempted to append both tables and instead of getting 3 columns, I got 4(finish attached). 

 

How do I append the two grouped tables so I get all users in one column, and don't get the fourth column?

[Image Can Not Be Found]

 
Posted : 19/01/2019 6:01 pm
(@catalinb)
Posts: 1937
Member Admin
 

Hi Mark,

There is no file attached.

Make sure the column names are the same in both queries, it's case sensitive.

 
Posted : 20/01/2019 2:02 am
Share: