moving companies : Computers : Databases : MySQL

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

2 of 6 people (33%) answered Yes
Recently 2 of 6 people (33%) answered Yes

Entry

I need to update field2 data with information from field1. How would I structure a statement.

Jan 30th, 2006 09:18
Lura Stiller, Bert Hoffbeck,


update my_table
set field2 = left(field1, 3)
where field1 = field1;
the left cmd just extracts a certain amount of data from the field1 
column.