900字范文,内容丰富有趣,生活中的好帮手!
900字范文 > ado .net oracle varray ADO.NET调用ORACLE 11g存储过程问题

ado .net oracle varray ADO.NET调用ORACLE 11g存储过程问题

时间:2020-02-08 07:10:18

相关推荐

ado .net oracle varray ADO.NET调用ORACLE 11g存储过程问题

我用 调用存储过程会出现

( - + case mod new not null

continue avg count current exists max min

prior sql stddev sum variance execute forall merge time

timestamp interval date

pipe

purge

符号 "(在 ":" 继续之前已插入。

存储过程是:

create or replace procedure usp_SetRoleRight

(

v_roleid in integer,

v_modelid in integer,

v_rightid in integer,

v_enabled in integer

)

is

v_rowcount int;

begin

select count(*) into v_rowcount from T_roleright where roleid=v_roleid and modelid=v_modelid and rightid=v_rightid;

if v_rowcount = 0 then

insert into T_roleright(ROLERIGHTID,roleid,modelid,rightid,enabled) values(S_T_ROLERIGHT.Nextval, v_roleid,v_modelid,v_rightid,v_enabled);

else

update T_roleright set enabled=v_enabled where roleid=v_roleid and modelid=v_modelid and rightid=v_rightid;

end if;

commit;

end usp_SetRoleRight;

我调用的方法是:

OracleConnection connection = new OracleConnection(connectionString);

OracleDataReader returnReader;

connection.Open();

OracleCommand command = BuildQueryCommand( connection,storedProcName, parameters );

mandType = CommandType.StoredProcedure;

returnReader = command.ExecuteReader(CommandBehavior.CloseConnection);

希望大家帮忙下!

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。