1.在oracle中,数据表别名不能加as,如:select a.appname from appinfo a;-- 正确select a.appname from appinfo as a;-- 错误也许,是怕和oracle中的存储过程中的......
6、如果在存储过程中,使用如下语句: select sum(vcount) into fcount from A where bid='xxxxxx';如果A表中不存在bid="xxxxxx"的记录, 则fcount=null(即使fcount定义时设置了默认值,如:fcount number(8):=0依然无效,fcount还是会变成null), 这样以后使用fcount时就可能有问题,所以在这里最好先判断一下:
if fcount is null then fcount:=0; end if;这样就一切ok了。