Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I am facing mapping loading issue for the below script.
Please help to fix the issue.
MapCountry:
Mapping LOAD
[ID,Country
1,INDIA
2,Singapore
3,US
4,UK
5,Japan
];
Data:
LOAD *,
ApplyMap('MapCountry', ID) As Country,
ID & Name & Country As Key;
LOAD * inline [
ID,Name
1,A
2,B
3,C
4,D
5,E
6,F
7,G
8,H
9,I
10,J
];
EXIT Script;
Hi
Try like this
MapCountry:
Mapping LOAD * Inline
[
ID,Country
1,INDIA
2,Singapore
3,US
4,UK
5,Japan
];
Data:
LOAD *,
ID & Name & Country As Key;
LOAD *, ApplyMap('MapCountry', ID, 'N/A') As Country inline [
ID,Name
1,A
2,B
3,C
4,D
5,E
6,F
7,G
8,H
9,I
10,J
];
EXIT Script;
HI,
Try this script
MapCountry:
Mapping LOAD
* INLINE // You missed this line
[ID,Country
1,INDIA
2,Singapore
3,US
4,UK
5,Japan
];
Data:
LOAD
*,
ID & Name & Country As Key; // Moved this line to 3rd precedent load.
LOAD *,
ApplyMap('MapCountry', ID) As Country;
LOAD * inline [
ID,Name
1,A
2,B
3,C
4,D
5,E
6,F
7,G
8,H
9,I
10,J
];
Hi
Try like this
MapCountry:
Mapping LOAD * Inline
[
ID,Country
1,INDIA
2,Singapore
3,US
4,UK
5,Japan
];
Data:
LOAD *,
ID & Name & Country As Key;
LOAD *, ApplyMap('MapCountry', ID, 'N/A') As Country inline [
ID,Name
1,A
2,B
3,C
4,D
5,E
6,F
7,G
8,H
9,I
10,J
];
EXIT Script;
Thank you so much jagan and MayilVahanan.
Thank you jagan for correcting me where I was wrong.
You can try it
Data:
LOAD *,
ID & Name & ApplyMap('MapCountry', ID) As Key;