Solved

How can I replace $$ with $ where its part of field in MySQL ?

Posted on 2010-09-15
2
317 Views
Last Modified: 2012-05-10
I've just noticed I have $$ at the start of all my prices.

I need to correct this, so that I have $ instead.

I need an update query to fix this..
0
Comment
Question by:mindwarpltd
2 Comments
 
LVL 19

Accepted Solution

by:
Bhavesh Shah earned 250 total points
ID: 33681745
GENERALLY IT IS LIKE

UPDATE TABLENAME
SET COLUMN1 = REPLACE(COLUMN1,'$$','$')
where column1 like '%$$%'
0
 
LVL 7

Assisted Solution

by:waltersnowslinarnold
waltersnowslinarnold earned 250 total points
ID: 33681769
Use the following code sample
UPDATE TableName

SET COLUMN1 = REPLACE(COLUMN1,'$$','$')

WHERECOLUMN1 like '$$%'

Open in new window

0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now