Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

Share this Page URL

Chapter 1. Introduction > The New Oracle10g BINARY_FLOAT and BINARY_DOUBLE Type... - Pg. 22

22 Oracle Database 10g SQL CAUTION If you forget to add a WHERE clause, all the rows will be updated. This is typically not the result you want. Notice that the SET clause is used in the previous UPDATE statement to specify the column and the new value for that column. You can confirm the previous UPDATE statement did indeed change customer #2's last name using the following query: SQL> SELECT * 2 FROM customers 3 WHERE customer_id = 2; CUSTOMER_ID FIRST_NAME LAST_NAME DOB PHONE ----------- ---------- ---------- --------- ------------ 2 Cynthia Orange 05-FEB-68 800-555-1212 Removing a Row from a Table You use the DELETE statement to remove rows from a table. As with the UPDATE statement, you typically use a WHERE clause to limit the rows you wish to delete--if you don't, all the rows will be deleted from the table. The following example uses a DELETE statement to remove the row from the customers