SQL Query/Update

badkarma1399

Senior member
Feb 21, 2007
688
2
0
Hi, I'm currently trying to learn a bit of SQL, but I need some help forming a query...well an update to be exact. I have a table (called snails) that contains several characteristics for each record (their height, length, etc). Lets say I wanted multiply two of these characteristics together, and update that product to a third column? (Let say named height*length) Further, I'd like to do this for each record. Anyone know how to do this? Thanks for reading and any help.
 

KLin

Lifer
Feb 29, 2000
30,950
1,076
126
UPDATE snails set column3 = height*length

This better not be a homework question.
 

BoberFett

Lifer
Oct 9, 1999
37,562
9
81
This really should be covered by any SQL for Dummies book. Updates don't get simpler than this.