One, add data
/* Add Data * *
INSERT INTO STU values (' stu0004 ', ' Zhao Yi ', 18,1, "kc0004");
Insert into STU (stu_id,stu_name,stu_age,stu_set) VALUES (' stu0013 ', ' storage 11 ', 19, 1);
Note: If you do not specify to add data to that field, then you must list all the data, if the field is listed, one by one corresponds, you must list all the fields with the constraint not empty, or the error.
Ii. Updating of data
/* Update Data * *
STU SET stu_age=19 WHERE stu_id= ' stu0001 '
Description: After set for the data you want to update, where is the condition
Third, add column
/* Add Column * *
ALTER TABLE STU ADD kc_no varchar2 (10)
Description: Add kc_no column in Stu, you cannot set constraint is not NULL, unless there is no data in Stu
Four, function
/* Average *
/select AVG (stu_age) as average from STU
/* There is a worth of rows
/select COUNT (stu_id) as rows from STU
Select COUNT (kc_no) as row count from Stu
/* Maximum
/select Max (stu_age) as maximum age from STU
/* min
/select min (stu_age) as minimum age from STU
/* Sum *
/select SUM (Stu_age) as and from STU