Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
How can we merge values of a field in script. For ex;
Disease
A
B
C
D
and here i want 2 values c & d to get merged into 1 value nd named as others?
Please help.
I think this will help
load
area,
project,
if(disease='a' or disease='b', disease,null())as disease,
if(disease='c' or disease='d',disease , null())as others
from
xyz.xlsx;
-Sundar
C & D are the values not the fields
It is like
Disease
A
B
C
D
and in script while loading:
load
Area,
Disease,
Project
from xyz.xlsx
and now i want to merge the values in disease.
See the Attached
Regards
Aviral Nag
Hm, I think that will almost work, maybe this:
Temp:
LOAD Area,
Project,
Disease
FROM xyz.xlsx;
Real:
LOAD *,
if(Disease='A' or Disease = 'B','Disease') as Others
if(Disease='C' or Disease = 'D','Disease') as Others
In this, others is coming as a separate field and Disease as separate but i want others to be included as a value.
What exactly you want. Explain your requirement on Excel.
Hi Aakansha,
Please update sample file,so able to help
In the Attached I have provide you 2 Fields named as others & Others11:
Try this:
if(WildMatch(Disease,'C','D'),'Others',Disease) AS Others
Regards
This is the requirement.
I have tried this. but this creates one extra field others.
and i want others to be a value of disease as mentioned in Ex.xlsx