一个存储过程代码:
参数:
IN uid int;
OUT bgcount int;
存储过程名称:userproc,代码:
select count(*) into bgcount from userdata where Uid =uid;调用 call userproc(1,@a);
select @a;跟一段SQL:
select count(*) into @bgcount from userdata where Uid =1;
select @bgcount;执行的结果不一样 你们遇到过吗 同样的代码 同样的参数 就是执行结果不一样 什么情况啊
参数:
IN uid int;
OUT bgcount int;
存储过程名称:userproc,代码:
select count(*) into bgcount from userdata where Uid =uid;调用 call userproc(1,@a);
select @a;跟一段SQL:
select count(*) into @bgcount from userdata where Uid =1;
select @bgcount;执行的结果不一样 你们遇到过吗 同样的代码 同样的参数 就是执行结果不一样 什么情况啊
IN v_uid int;
OUT bgcount int;
存储过程名称:userproc,代码:
select count(*) into bgcount from userdata where Uid =v_uid;
http://topic.csdn.net/u/20090501/15/7548d251-aec2-4975-a9bf-ca09a5551ba5.html
http://topic.csdn.net/u/20100428/09/BC9E0908-F250-42A6-8765-B50A82FE186A.html
http://topic.csdn.net/u/20100626/09/f35a4763-4b59-49c3-8061-d48fdbc29561.html8、如何给分和结贴?
http://community.csdn.net/Help/HelpCenter.htm#结帖