replacing values in MySQL
by "Keith D Sellars" <Keith(at)webgraffix.com>
|
| Date: |
Mon, 21 Apr 2003 12:10:19 -0400 |
| To: |
<hwg-languages(at)hwg.org> |
| |
todo: View
Thread,
Original
|
|
I have a MySQL db with several tables, each of which has multiple fields.
If I want to replace all of the values of one field in a specific table
with, say the number "2", what is the correct command syntax?
Assume:
Table Name: orders
Field Name: status
I want to replace the "status" field in all rows with: 2
Checking the mysql.com site, I am a little confused by the "replace" and
"update" commands. I do not want to change anything else, including any
auto-incrementing values.
Thanks in advance,
Keith D Sellars
WebGraffix
www.webgraffix.com
"Making database sites seem easy"
HWG: hwg-languages mailing list archives,
maintained by Webmasters @ IWA
This page is part of a preserved archive of archives.hwg.org. The site is no longer active and its content is not maintained. For enquiries about this archive, write to archive(at)iwanet.org.