Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

joeybird
Contributor II

match values from same columns but different tables


qlik sense

Hiya

I have two tables

Table A and Table B

in both tables they have the same column name -TimeDaySessions

Table A -TimeDaySessions

shows , Morning, Afternoon, All Day

Table B -TimeDaySessions

shows , M, A, D

I wish these vales to match, is there a way in the data load to do find and replace? I wish for both columns to say Morning, Afternoon, All Day

Please help

1 Solution

Accepted Solutions
oscarmqz
Contributor III

Re: match values from same columns but different tables

Use an if condition in your load

LOAD

IF(TimeDaySessions='M','Morning',IF(TimeDaySessions='A','Afternoon','All Day')) as TimeDaySessions

4 Replies
oscarmqz
Contributor III

Re: match values from same columns but different tables

Use an if condition in your load

LOAD

IF(TimeDaySessions='M','Morning',IF(TimeDaySessions='A','Afternoon','All Day')) as TimeDaySessions

ogster1974
Honored Contributor II

Re: match values from same columns but different tables

LOAD

pick(match(TimeDaySessions,'M','A','D'), 'Morning','Afternoon','All Day') as TimeDaySessions

Might load quicker.

krishna_2644
Valued Contributor III

Re: match values from same columns but different tables

As Ogster1974 Mentioned try

1:

load * inline [

TimeDaySessions

Morning

Afternoon

All Day

];

2:

NoConcatenate

load

pick(match(TimeDaySessions,'M','A','D'), 'Morning','Afternoon','All Day') as TimeDaySessions;

load * inline [

TimeDaySessions

M

A

D

];

joeybird
Contributor II

Re: match values from same columns but different tables

Hiya

Thanks all

kind regards