Re: help!! how to call pl/sql anonymous block from java?

From: Mladen Gogala <gogala.mladen_at_gmail.com>
Date: Tue, 18 Feb 2014 16:09:09 +0000 (UTC)
Message-ID: <pan.2014.02.18.16.09.10_at_gmail.com>


On Tue, 18 Feb 2014 05:41:05 -0800, abhishek.anne wrote:

>>     // register the output parameter
>>     oracs.registerOutParameter(1,OracleTypes.CURSOR);

>
>
> Hello,
>
> How could use same for SQL Server.

You cannot use PL/SQL in SQL Server, unless I'm very much mistaken. The only two databases that support PL/SQL are Oracle and DB2. For those surprised by the latter database, the documentation is here:

http://pic.dhe.ibm.com/infocenter/db2luw/v9r7/index.jsp?topic=%2Fcom.ibm.db2.luw.apdv.plsql.doc%2Fdoc%2Fc0053607.html http://pic.dhe.ibm.com/infocenter/idmhelp/ds-v2r2/index.jsp?topic=%2Fcom.ibm.datatools.routines.plsql.doc%2Ftopics%2Ftplsqlrun.html

>
> I am unable find equivalent for OracleTypes.CURSOR?

Local temporary table is the equivalent. You will have to use T-SQL. I have to commend you for working directly with JDBC and not using some DB agnostic Java framework like Hibernate.

-- 
Mladen Gogala
The Oracle Whisperer
http://mgogala.byethost5.com
Received on Tue Feb 18 2014 - 17:09:09 CET

Original text of this message