在SQL里是这样的。如果写在oracle里该怎么写呢?Create PROC backtable @SN varchar(20)As
select count(*)
from Customization
where SN=@SN
GO
select count(*)
from Customization
where SN=@SN
GO
解决方案 »
- 大家好,我有一个字符集的问题,谁能帮帮我啊
- 用sql语句重命名一个表,放到produce里面就不行了?
- 在Oracle10g上开发,最后部署到Oracle9i上,会有问题吗?
- 圣诞快乐 - 9i新函数
- 初学者的问题,快照是做什么的,如何调用
- db中知道如何知道一个已知名字的procedure存在于哪个package中?
- 192的内存,P3 CPU专门用于ORACLE服务器,SGA的大小设多少最为合适?
- 请高手指教,Developer 2000的问题!
- 怎样配置thin方法连接数据库!
- 数据类型blob的问题
- 请问用户自己的表、索引、store procedure 等SQL放在哪个表?
- 如何将A数据库内的相关发生记录所涉及的表数据定期迁移至B数据库内
/
create or replace package pkg_test
is
type ResultData is ref cursor;--定义动态游标
procedure test( rst out ResultData );
end pkg_test;
/
create or replace package body pkg_test
is
procedure test( rst out ResultData )
is
begin
open rst for
select count(*)
from Customization
where SN=ASN;
--返回select * from t所查询的结果集
end;
end pkg_test;
/
v_SN varchar
v_Cnt out number
)Asbegin select v_Cnt = count(*)
from Customization
where SN= v_SN;end backtable ;