Solved

find and replace mysql

Posted on 2014-10-24
3
269 Views
Last Modified: 2014-10-25
In this case, I have several tables which have a clientid of 30.
I need to find every single instance and switch those over to clientid 150.

I am using phpmyadmin in this case but can also do this from the command line if needed.

mysql-server-5.5.40
0
Comment
Question by:projects
  • 2
3 Comments
 
LVL 50

Accepted Solution

by:
Steve Bink earned 500 total points
ID: 40404055
Quick and dirty..  For each of the tables you need to change:
UPDATE <tablename> SET clientid=150 WHERE clientid=30

Open in new window

0
 

Author Comment

by:projects
ID: 40404379
Thank you. I'm amazed that I wasn't able to find something this simple when searching the net.
0
 
LVL 50

Expert Comment

by:Steve Bink
ID: 40404440
You can find more information in the MySQL docs.  Good luck!
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Does the idea of dealing with bits scare or confuse you? Does it seem like a waste of time in an age where we all have terabytes of storage? If so, you're missing out on one of the core tools in every professional programmer's toolbox. Learn how to …
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…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

911 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

22 Experts available now in Live!

Get 1:1 Help Now