mysql函數(shù)可以返回多個值嗎
1 回答

手掌心
TA貢獻1942條經(jīng)驗 獲得超3個贊
用存儲過程算了,函數(shù)不能返回一個值,如果要返回多值的話,那就返回一個table,用存儲過程同樣能達到效果
CREATE PROCEDURE `goodcheck`(
in xxx int
in xxx
...
out xxx ..
out xxx char
)
begin
select sum(productstockinfo.num) into production from productstockinfo where pro_id=productId;
添加回答
舉報
0/150
提交
取消