I expect this is an easy answer, but I can't figure out the right terms to search for.
I would like to add a comma in between any company name and "INC" (or, as it may be, "LLC", "LP", etc.). For example, I want 'COMPANY INC'
to be 'COMPANY, INC'
where 'COMPANY'
could be any company name you might think of. It could have letters, numbers, but probably not special characters.
REGEXP_REPLACE("COMPANY A LP', '[a-zA-Z0-9] LP', ', LP')
of course only returns 'COMPANY , LP'
; how do I keep the A
so that it returns COMPANY A, LP
?
EDIT:
There are also already valid records with the appropriate comma, i.e. COMPANY A, INC
also already exists.