设为首页 加入收藏

TOP

mysql 存储过程 incorrect number of arguments
2011-06-12 21:29:52 来源: 作者: 【 】 浏览:56次 评论:0

mysql教程 存储过程 incorrect number of arguments

DROP PROCEDURE `chaxun_name_ps教程`//
CREATE DEFINER=`root`@`localhost` PROCEDURE `chaxun_name_ps`(in c_id

int,out c_phone char,out c_pwd char)
    READS SQL DATA
begin
select phone,pwd
from caopanshou
where id = 18;
select found_rows() into c_phone,c_pwd;
end


调用方法

call chaxun_name_ps(1,1,1)

不知道 方法

select @chaxun_name_ps()

返回值为Null


有些朋友可能不知道found_rows()函数的功能

select count (*) from t 相同功能的mysql函数found_rows

<?php教程

    $sql = "select count(*) from t";

    $res = mysql_query($sql);

    $num = mysql_result($res,0);

    $sql =  "select topic,detail from t limit 5";

    //***以下我就不写了

?>


然而用mysql自带函数found_rows();

您看到此篇文章时的感受是:
Tags: 责任编辑:administrator
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
分享到QQ空间
分享到: 
上一篇php 实现MySQL里动态视图代码 下一篇mysql 获取季度的第一天 本月的第..

评论

帐  号: 密码: (新用户注册)
验 证 码:
表  情:
内  容:

相关栏目

最新文章

图片主题

热门文章

推荐文章

相关文章

广告位