Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have a field that is the document number of the invoice.
This field will have some strings like . or / or - or etc
how can i remove from all data these strings that have come from false data entry.
I tried with the the following command
IF(FINDONEOF(DOC_PURCHASES,'.'),REPLACE(DOC_PURCHASES,'.',''),
IF(FINDONEOF(DOC_PURCHASES,'/'),REPLACE(DOC_PURCHASES,'/',''),
IF(FINDONEOF(DOC_PURCHASES,'-'),REPLACE(DOC_PURCHASES,'-',''),
IF(FINDONEOF(DOC_PURCHASES,','),REPLACE(DOC_PURCHASES,',',''),
DOC_PURCHASES))))
but in some values does not work and i don't know why.
Have anyone an idea how can i do this.
Thank you in advance.
what if you try using purgecharacter function?
purgechar(DOC_PURCHASES,'.-/')
what if you try using purgecharacter function?
purgechar(DOC_PURCHASES,'.-/')
As @Frank_Hartmann suggested you can either use purgechar function in which you can write as many junk characters that you want to remove. If single quotes itself is one of the junk character then you can use it like below
=PurgeChar(DOC_PURCHASES,chr(39)&'-.,')
If you field always going to have number value then you can use keepchar function which will automatically remove all other characters from field
Keepchar(DOC_PURCHASES,'0123456789')