Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
How to Rename Field in Inline,XMLetc..
Hi,
there are functions such as Rename, Replace.
Simply you could alias 'as'
Not sure whether I'm answering your exact requirement
Thanx
for inline you need to use resident load and rename fields.
let see one example
TEST:
Load * Inline [
SaleId, product, Sale
001, ABC, 200
002, PQR, 300
];
NoConcatenate
TEST2:
Load SaleId,
product as SaleProduct,
Sale as SaleAmount
Resident TEST;
drop table TEST;
same u can "as" keyword for XML load.
-- Regards,
Vishal Waghole
Yogesh,
Is this for QliK Sense or Qlikview personal edition?
Gio
Check the Qlik Sense online Help. Below is the entry for Rename Field.
This script function renames one or more existing Qlik Sense field(s) after they have been loaded.
Either syntax: rename field or rename fields can be used.
Syntax:
Rename Field (using mapname | oldname to newname{ , oldname to newname })
Rename Fields (using mapname | oldname to newname{ , oldname to newname })
Arguments:
Argument | Description |
---|---|
mapname | The name of a previously loaded mapping table containing one or more pairs of old and new field names. |
oldname | The old field name. |
newname | The new field name. |
Limitations:
Two differently named fields cannot be renamed to having the same name. The script will run without errors, but the second field will not be renamed.
Example 1:
Rename Field XAZ0007 to Sales;
Example 2:
FieldMap:
Mapping SQL Select oldnames, newnames from datadictionary;
Rename Fields using FieldMap;
Hi Yogesh
1) Renaming Fields in Inline:
Load *, Name as NewName Inline [
Name
Yogesh
Rajesh
]
2) Other files:
Simply by using AS or Alias
eg. Load *,
Name,
Name as NewName
From ...
Regards
Aviral Nag