Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
HI ALl,
I have writtena Apply Map in the script .
and after reloading it gives me the error .
please find the screenshot of the error and the script
Tahnks in Advance
Where are you loading the data from for the test2 load?
Your screen shot is missing the details of the from line.
Does the field RSeverity exist in the table you are loading test2 from?
Hi Collin,
No the Test2 Table doesnt have RSeverity field ...
Iam trying to bring it by using the apply map function
Hi Roy,
If RSeverity field is not available in the second table, then apply map won't work.
This general syntax will help you to understand.
Map_Table_Name:
Mapping
Load
Mapping_key,
Field_to_be_Mapped
From....
Second_table:
load
Applymap('Map_Table_Name',Map_Field_From_Second_Table,'Not Available then') as Fileld,
.....
from
......
Here Map_Field_From_Second_Table is nothing but the Key in the Second_Table which is tallying with Mapping_key in the Map_Table
Rgds,
Tharindu
The ApplyMap function is used to translate a field from one value to another. The field you are translating must exist in the data.
The source data for test2 MUST contain RSeverity then applymap function will translate the value and return the second value from the mapping table. If the data does not contain RSeverity, then you get the error you are seeing.
Look at this post to see how Applymap works.
Hi,
when your writing the applymap syntax in the table you have to give the field name for comparison with in the table.
example:
Map:
Mapping load
id,name
from map.xlsx;
table:
load
ids,
applymap('Map',ids) as name,
sal,
dept
from sales.xlsx;
as you see above example am comparing id and ids and am mapping name.
while writing the field name have to give comparing field name that is available with in the table.