![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi, I am trying to create an update statement that will replace values based on a wild card and only replace the wild card data (not the entire field). Does anyone have any suggestions? Is this even possible? Here is my code: UPDATE UPDATE MyTable SET MyField = replace(MyField, '*[0-9][0-9][0-9][0-9][0-9]*' , 'XXXXX') WHERE (MyTable.MyField) Like '*[0-9][0-9][0-9][0-9][0-9]*' Replace() is a function. I suppose you could create a function in a |
#3
| |||
| |||
|
#4
| |||
| |||
|
|
Hi, I am trying to create an update statement that will replace values based on a wild card and only replace the wild card data (not the entire field). Does anyone have any suggestions? Is this even possible? Here is my code: UPDATE UPDATE MyTable SET MyField = replace(MyField, '*[0-9][0-9][0-9][0-9][0-9]*' , 'XXXXX') WHERE (MyTable.MyField) Like '*[0-9][0-9][0-9][0-9][0-9]*' |
#5
| |||
| |||
|
|
Hi, Thank you very much for the response. So are you suggeting that I remove all characters that are not numeric from my field using a SPLIT Function? Do you happen to have an example of this? Thank you again! |
#6
| |||
| |||
|
#7
| |||
| |||
|
#8
| |||
| |||
|
|
Hi John, what would I change to be able to search for 5 consecutive numbers anywhere within the string? Thank you again! |
#9
| |||
| |||
|
|
Hi John, what would I change to be able to search for 5 consecutive numbers anywhere within the string? Thank you again! |
#10
| |||
| |||
|
![]() |
| Thread Tools | |
| Display Modes | |
| |