i have customer name and customer code together
ex-
D300098-Abhay Singh
E100094-B.Ahlawat
w9995ii - xyz
i want the names only from them.
i have tried Left and Right function but not getting proper result.
can any one help me in that.
regards
abhay
Hi,
For name try this
SubField(YourField,'-', 2) as Name
For Customer code try this
SubField(YourField,'-', 1) as CustomerCode
Regards
ASHFAQ
Try with subfield(), like:
Load
SubField(YourStringField,'-', 2) as Name
Hi,
Try this
Table:
Load code_Name,
subfield(code_Name,'-',1) as code,
trim(subfield(code_Name,'-',2)) as Name
From Table;
try like this
keepchar(yoursting,'a-z')
Hi,
For name try this
SubField(YourField,'-', 2) as Name
For Customer code try this
SubField(YourField,'-', 1) as CustomerCode
Regards
ASHFAQ
SubField(YourFieldName,'-',-1) as Name
thanks ashfaq it is working
Please close the thread by selecting appropriate answers.
Regards
ASHFAQ
Hi, you also can try:
Trim(Mid(YourField, Index(YourField, '-')+1))
this is getting me only character "a, - , z"