Happy New Year to all!
Might this be the correct SRPL syntax for replacing a substring within a
text column? If not, what?
SET VAR vTargetColumn TEXT = NULL
SET VAR vTargetColumn = 'ColumnNAME'
UPDATE TableNAME SET &vTargetColumn =
(SRPL(&vTargetColumn,'SearchString','ReplaceString',0))
I ask because I attempted a SRPL on a column using a literal string in
place of '&vTargetColumn', with an ugly result (Fortunately I had a
backup. )
Target column 'transx' contained several thousand values [ V00xxxxxx |
v00xxxxxx ] where 'x' might be any digit. For visual
clarity-in-reporting's sake, I decided to replace the legacy capital 'V'
with lower case 'v'.
UPDATE transx SET trxnum = (SRPL('V0','V','v',0)) WHERE trxnum LIKE
'V0%'
This produced a uniform value of 'v0'. No trailing digits. Disaster.
Restore from backup.
???
Thanks very much,
Bruce Chitiea
SafeSectors, Inc.
909.238.9012 m
--
For group guidelines, visit
http://www.rbase.com/support/usersgroup_guidelines.php
---
You received this message because you are subscribed to the Google Groups "RBASE-L" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.