Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have the field PharmacyName that I want to change to PharmacyDemo as follows.
PharmacyName change to PharmacyDemo
PharmacyA change to Pharmacy1
PharmacyB change to Pharmacy2
PharmacyC change to Pharmacy3
PharmacyName is a field that already exists in the model.
PharmacyDemo does not exist in the model
How can I do this?
See here: http://community.qlik.com/blogs/qlikviewdesignblog/2012/09/25/how-to-rename-fields
so I have this in my script
DemoMapping:
Mapping LOAD PharmacyName, PharmacyDemo
FROM
(ooxml, embedded labels, table is Sheet1);
Rename Fields using DemoMapping;
but it's not working.
I have the listbox with PharmacyName on each sheet of my QlikView Model,
on the first sheet, it changes PharmacyName to PharmacyDemo, but says the field is unavailable.
On all the other sheets PharmacyName has not change to PharmacyDemo
Try this:
DemoData:
LOAD *
FROM
(ooxml, embedded labels, table is Sheet1);
DemoMapping:
Mapping LOAD * inline [
OldName, NewName
PharmacyName, PharmacyDemo
PharmacyA, Pharmacy1
PharmacyB, Pharmacy2
PharmacyC, Pharmacy3
];
Rename Fields using DemoMapping;
In this case I used and inline table, but if you have a lot of fields it's easier to maintain it in a seperate text or excel file as in Henric's blog post.
Hi,
If you are renaming only one field then instead of Mapping load you can straight away rename it by using
Rename field OldFieldName to NewFieldName;
Regards,
Jagan.
Hi there,
I find your method really useful! however, what if the field value that I am changing has a comma in it?
e.g. Fieldvalue 1 is Marketing, Branding and Analytics which I want to change to Fieldvalue 2 which is Marketing, Analytics?
Looking forward to your reply and thanks!
Hi there,
I find your method really useful! however, what if the field value that I am changing has a comma in it?
e.g. Fieldvalue 1 is Marketing, Branding and Analytics which I want to change to Fieldvalue 2 which is Marketing, Analytics
Looking forward to your reply and thanks!