当前位置:Gxlcms > mysql > select-用MySql的Navicat创建存储过程总是报1458错误

select-用MySql的Navicat创建存储过程总是报1458错误

时间:2021-07-01 10:21:17 帮助过:327人阅读

selectmysql存储过程

下面是我穿件存储过程的代码。求大神帮忙看看。真心很急,明天就要用。

 create procedure searchStudentGrade(in id char) begin     if id is null         select  student.StudentID,student.StudentName,student.ClassNumber,grade.ExamID,course.CourseName,grade.Grade,course.CourseID        from student,grade,course        where student.StudentID=grade.StudentID and grade.CourseID=course.CourseID;    else        select student.StudentID,student.StudentName,student.ClassNumber,grade.ExamID,course.CourseName,grade.Grade,course.CourseID        from student,grade,course        where student.StudentID=grade.StudentID and grade.CourseID=course.CourseID and grade.StudentID=id;    end if;end;

人气教程排行