Re: Help! PL/SQL Stored Procedures
Date: 1998/06/15
Message-ID: <3587f04b.14017115_at_192.86.155.100>#1/1
A copy of this was sent to Guillaume CHAPUS <gchapus_at_ifhamy.insa-lyon.fr> (if that email address didn't require changing) On Mon, 15 Jun 1998 10:36:46 +0200, you wrote:
>Hi all,
>
>I need to migrate a MS SQL Server database to an Oracle7 database.
>I'm worried about the migration of my T-SQL stored procedures.
>Should I rewrite all my procedures ?
>And does it affect the way of sending data to the Client ?
>
>So a few questions about PL/SQL stored procedures :
>
>* Does PL/SQL stored procedures support input and output variables ?
>
Yes it does.
>* Can PL/SQL stored procedures return a result set with multiple rows ?
>And how ?
>
Yes it can, with cursor variables. It will look something like:
create or replace function sp_ListEmp return types.cursortype as
l_cursor types.cursorType;
begin
open l_cursor for select ename, empno from emp order by ename;
return l_cursor;
end;
/
where types is a package you wrote that defines a generic cursor type, ie:
create or replace package types
as
type cursorType is ref cursor;
end;
/
>* Can PL/SQL stored procedures return multiple different results ? And
>how ?
>
Yes, you just have to have N different formal parameters to the procedure -- each one being of type ref cursor.
>* Does it exist tools that can transform T-SQL procedures into PL/SQL
>procedures ?
>
Oracle's Design and Migration Services has such a tool
>* Does it exist documentation on this problem ?
>
and documentation. Please contact your sales ref for info on getting these tools.
>
>Thanks in advance
Thomas Kyte
tkyte_at_us.oracle.com
Oracle Government
Herndon VA
http://govt.us.oracle.com/ -- downloadable utilities
Opinions are mine and do not necessarily reflect those of Oracle Corporation
Anti-Anti Spam Msg: if you want an answer emailed to you, you have to make it easy to get email to you. Any bounced email will be treated the same way i treat SPAM-- I delete it. Received on Mon Jun 15 1998 - 00:00:00 CEST