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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Renaming column names

Hi,

I developed a dashboard using Excel sheets as Source(Excel to QVD, QVD to dashboard). Now as a part of my project , I want to change my data source from Excel to Apache Hbase. But I dont want to change my data model.

But the problem is the column names from HBase as extra 'data:' for each column name.

For Example:

Excel SourceHbase Source
PRD_TYP_DSCdata:PRD_TYP_DSC
CD_TYP_DATEdata:CD_TYP_DATE
TOT_AMT_DUE_IN_GCdata:TOT_AMT_DUE_IN_GC

Now I want to remove that extra 'data:' from each column. I had some 1200 columns coming from 30 tables. So I want an automated way to use rather than manually using 'as'.

Regards,

Hemanth Dasari.

3 Replies
Not applicable
Author

Mark_Little
Luminary
Luminary

HI,

Maybe have a look at this,

Friendly Name using Rename.docx

A little self promotion.

Mark

jagan
Partner - Champion III
Partner - Champion III

HI,

You can rename all the columns in a single shot by using

FieldNameMap;

Mapping Load OldFieldName, NewFieldName From FieldNames ;

Rename Fields using FieldNameMap;

Example:

FieldNameMap

LOAD

*

INLINE [

NewFieldName, OldFieldName

PRD_TYP_DSC,data:PRD_TYP_DSC
CD_TYP_DATE,data:CD_TYP_DATE
TOT_AMT_DUE_IN_GC,data:TOT_AMT_DUE_IN_GC

];


Rename Fields using FieldNameMap;


Hope this helps you.


Regards,

jagan.