Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Announcements
BI & Data Trends 2021. Discover the top 10 trends emerging in today. Join us on Dec. 8th REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Master
Master

Rename fields by mapping table in Qlik Sense

Hi Folks,

does anybody have an example or qfv-file, how to rename fields in Qlik Sense by using of mapping table

Thanks a lot in advance

Beck

1 Solution

Accepted Solutions
Highlighted
Partner
Partner

Try this :

map:

mapping load * inline [

name, NewName

omar, OBS

];

table:

load id, ApplyMap('map',oldName,oldName) as NewName Inline [

id, oldName

1, omar

2, beck

]

;

result:

Capture.PNG

View solution in original post

10 Replies
Highlighted
Contributor III
Contributor III

Hi Beck,

You need to create a another Load statement to rename this using aliases.

complete your mapping and take resident of the fields you want and rename them.

Regards,

Rajan Kasbe

Highlighted
Partner
Partner

Hi Beck, can you elaborate with a simple example?

Maybe 2 dimensions, 4 or 5 lines of values and what you want to change and how?

Thanks

Highlighted
Master
Master

Hi Omar,

i find this issue:http://www.learnallbi.com/renaming-fields-in-qlikview-using-mapping-load/

i wanted to recreate this example, but i didnt achieve the correct results

Thanks a lot

Beck

Highlighted
Master
Master

HI Rajan,

first of all thanks a lot for your responce, do you have any example to your above explanation.

Thanks a lot

Beck

Highlighted
Partner
Partner

Try this :

map:

mapping load * inline [

name, NewName

omar, OBS

];

table:

load id, ApplyMap('map',oldName,oldName) as NewName Inline [

id, oldName

1, omar

2, beck

]

;

result:

Capture.PNG

View solution in original post

Highlighted
Master
Master

Omar, thanks a lot,

on the base of above link to issue of renaming of fields: i didn't know, that the Function: ApplyMap () must be used. I thought, the renaming of fields is possible only with Mapping load without ApplyMap().

Or am i missing something?

Beck

Highlighted
Partner
Partner

Mapping load table will contain the newName field .

You HAVE to use ApplyMap function to use the mapping load table.

Highlighted
Master
Master

Thanks a lot Omar

Highlighted
Partner
Partner

Hello Beck,

I tested the link you posted and it is working as expected in Qlik Sense (September 2017). I think you had a different issue if your fields were not renamed properly.

I executed the following script and it resulted in a table with fields "New Name A" and "New Name B":

LOAD * Inline

[a,b

abc,123

defg,456];

m_Fields:

MAPPING LOAD * Inline

[OldName,NewName

a,New Field A

b,New Field B

];

RENAME FIELDS using m_Fields;

Regards,

Mathias