Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi guys,
I have a field which has string values. I want to create a field flag if any of the values contain the word 'enter'.
[Location]
London,
singapore enter
china enter
enter Japan
India
Germany
This new field should seperate all values that do/dont have enter in them
Thanks,
Aaron
How about this?
If(Index(Location,'enter'), Location) as Enter_Location
Hi Aaron
In your load script try if(match('enter ',' enter'),'Y','N') as Flag this way you will capture locations that have space before the word enter or after. If there is no space after the word just amend to 'enter'
Kindest regards
Brian
How about this?
If(Index(Location,'enter'), Location) as Enter_Location
Hi Thanks for your response.
Where do i use the field [location]?
May be try this?
LOAD *,
Location,
IF(Wildmatch(Location, '*enter*') >0, Location) AS EnterLocation
FROM tablename;