chuijinbao
吹进宝
采纳率0%
2017-05-16 02:00 阅读 3.0k

oracle Plsql SQL窗口执行存储过程出错00900

1

创建存储过程语句:
create procedure MailingListCount(
ListCount OUT INTERGER
)
IS
v_row INTERGER;
BEGIN
select count(*) INTO v_rows
FROM Customers
WHERE NOT cust_eamil IS NULL;
ListCont :=v_rows;
END;
执行存储过程语句:
var ReturnValue NUMBER
EXEC MailingListCount(:ReturnValue);
SELECT ReturnValue;
执行环境:PL/SQL SQL窗口
报错信息:
ora-00900:invalid sql statement
图片说明
ora-00923:FROM keword not found where expected
图片说明

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享

2条回答 默认 最新

  • kaijkl cain-won 2017-05-16 02:54

    WHERE NOT cust_eamil IS NULL; 这句语法错误!应该是WHERE cust_eamil IS NOT NULL;

    点赞 评论 复制链接分享
  • qq_37849050 qq_37849050 2017-05-16 03:26

    有两处理错误:1.WHERE NOT cust_eamil IS NULL,正确的写法:where cust_email is not null;

                        2.调用的时候有错误:
                                                declare
                                                     ReturnValue number;
                                                begin
                                                   ReturnValue :=1;
                                                    MailingListCount(ReturnValue);
                                                end;
    
    点赞 评论 复制链接分享

相关推荐