By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,082 Members | 2,135 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,082 IT Pros & Developers. It's quick & easy.

Please help!!! Replace characters

P: 1

Hopefully someone can help. I have a column in a table "mobile" that have values like


i need a query that will remove the "0" at the beginning and replace with "0044"

any help is greatly appreciated.
Feb 15 '10 #1
Share this Question
Share on Google+
1 Reply

P: 122
This query would replace the first "0" with "0044":

Expand|Select|Wrap|Line Numbers
  1. Update [Mobile] Set [ColumnName] = "0044" & Right([ColumnName], Len([ColumnName]) - 1) Where [ColumnName] Like "0*"
This is assuming you only need to do this update once. If you run the query multiple times, it's going to keep replacing the first "0". If this isn't what you need, please provide more detail on what values can be in that field and how they need to be managed.
Feb 15 '10 #2

Post your reply

Sign in to post your reply or Sign up for a free account.