想请教下,mysql怎么创建查询任意表名信息的存储过程,自己这样写的存储过程不行
create procedure test(out testing varchar(10))
start
select * from testing;
end
$$
mysql> call test('test1') 自己有这么一个test1的表名, 想通过存储过程函数来实现查询表的所有信息,但到这里就出错了 ,创建存储过程是成功的。
更多 0
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
你那select * 是 查询所有的好吗。 肯定有错误, 你要具体到哪个表