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

Announcements
Qlik Connect 2026 Agenda Now Available: Explore Sessions
cancel
Showing results for 
Search instead for 
Did you mean: 
evansabres
Specialist
Specialist

Different Fields, Same Values

I have three fields; 'User' 'Employee Rewarding' and 'Employee Awarded'

All three fields have the same values, which are employee names. Two of them come from one table, while the other comes from a different table. Ideally, I want to name the field empNME and have it be a key, linking field.

What would the solution be for this?

1 Solution

Accepted Solutions
ahaahaaha
Partner - Master
Partner - Master

For example, as variant

Table1:

LOAD

[employee names1],

[employee names1] as Key

...

From ...


Table2:

LOAD

[employee names2],

[employee names3],

[employee names3] as Key

...

From ...


Both tables will be linked by field Key

View solution in original post

8 Replies
ahaahaaha
Partner - Master
Partner - Master

Hi Evan,

As variant, in both tables, you can create an additional key field with employee names, by which to link both tables, without affecting the already existing fields with employee data.

Regards,

Andrey

evansabres
Specialist
Specialist
Author

Andrey,

Thank you. What is the process for doing that, apologies, unfamiliar.

ahaahaaha
Partner - Master
Partner - Master

For example, as variant

Table1:

LOAD

[employee names1],

[employee names1] as Key

...

From ...


Table2:

LOAD

[employee names2],

[employee names3],

[employee names3] as Key

...

From ...


Both tables will be linked by field Key

vamsee
Specialist
Specialist

Hi

Map:

Mapping Load   Employee_Awarded as Key,

                           Employee_Awarded as Value;

User:

Load User,

          EmployeeRewarding,

          ApplyMap('Map', User, NULL()) as  EmployeeAwarded

From A;

evansabres
Specialist
Specialist
Author

Apologies, I am not following, perhaps because I explained the order of my tables incorrectly.

My First Table is Transactions, which has fields

'EmployeeAwarded' and 'EmployeeRewarding'

My other table is Users, which has the field, 'User'

vamsee
Specialist
Specialist

Same thing just interchange the column names

                         ( or)

Map1:

Mapping Load   Employee_Awarded as Key,

                           Employee_Awarded as Value;

Map2:

Mapping Load

                         EmployeeRewarding as key,

                         EmployeeRewarding as Value;

User:

Load

           User,

          ApplyMap('Map2',User, Null()) as    EmployeeRewarding,

          ApplyMap('Map1', User, NULL()) as  EmployeeAwarded

From A;

vishsaggi
Champion III
Champion III

You said your EmployeeAwarded and EmployeeRewarding has employee names, you mean does these two fields has same employee names or different names. Just rename your User table Userfield to EmployeeAwarded. Like

Transactions:

LOAD EmployeeAwarded,

          EmployeeRewarding,

          ....

FROM yoursourcetablename;

User:

LOAD User AS EmployeeAwarded,

          ......

FROM yourSourcetablename;

evansabres
Specialist
Specialist
Author

Thank you!