在mysql的环境下,写了个带输入参数的存储过程delimiter //
create procedure spStu_withParam
(in studentname varchar(8))
begin
select * from student
where student_name=studentname;
end
//然后看了其他资料有另一种写法(与上述功能一样)
create procedure spStu_withParam
@studentname varchar(8)
as
select * from student
where student_name=@studentname但是第二个达不到效果,不知道是什么原因啊,不是my-sql的语法吗?
还是什么地方写错了啊?
create procedure spStu_withParam
(in studentname varchar(8))
begin
select * from student
where student_name=studentname;
end
//然后看了其他资料有另一种写法(与上述功能一样)
create procedure spStu_withParam
@studentname varchar(8)
as
select * from student
where student_name=@studentname但是第二个达不到效果,不知道是什么原因啊,不是my-sql的语法吗?
还是什么地方写错了啊?
mysql里怎么打印一句话啊?
如:要输出 '请重新输入学生信息'