[Fill in the blank question 1] share the computer grade level two questions, the simulated questions are for reference

I hope you get good results in the test, and I hope you can pass the test, and then report to the next three levels. I don't know if I can post it or want to share it:

Use the following SQL statement to create a stored procedure in the database XK to implement a course number course_id in the given table course, and you can specify a new classroom for the course corresponding to the course number in the table course.

USE XK :
DELIMITERS $$
CREATE _______ SP_UPDATE_ROOM(in cid int,in rno char(20))
BEGIN
update course set room = rno where course_id = ______;
end _______

I forgot to remember the subject of a trigger above, but I have the code. It
seems to create a trigger to automatically delete the student's course selection information.

USE XK ;
CREATE ______ TRIGGER_DELETE_STUDENT_BEGIN____DELETE
ON ____ FOR EACH ROW
DELETE FROM ______ WHERE STU_NO=OLD.STU_ID;

note:

The sj22.txt file in the folder shows part of the program, but it is incomplete. Please fill in the appropriate content on the horizontal line and delete the horizontal line, and save the original file name.

Guess you like

Origin blog.csdn.net/weixin_54161400/article/details/114992398