Results 1 to 3 of 3
  1. #1
    Join Date
    Dec 2002
    Posts
    2

    Unanswered: Returning multiple tables from a function

    Hi,

    I have a SQL Server 2000 db that I am currently converting to Oracle 9. In the SQL Server db I have a number of procedures that return recordsets. In Oracle I believe the only way to do this is to build a pl/sql table in a function and return the table.

    While somewhat laborious this method works apart from in one instance where the SQL Server procedure returns two recordsets.

    Basically my questions are:

    1. Is there a better way of returning a recordset from a function/procedure in Oracle?

    2. Is it possible to return two recordsets from a function/procedure in Oracle?

    Thanks in advance
    Jamie.

  2. #2
    Join Date
    Nov 2002
    Location
    Desk, slightly south of keyboard
    Posts
    697
    Hi,

    Q1: Yes, search on here or google for REF CURSOR, there should be plenty of examples.

    Q2: I haven't tried it, but I don't see why you shouldn't be able to use two REF CURSORS.

    Hth
    Bill

  3. #3
    Join Date
    Dec 2002
    Posts
    2
    Thanks Bill.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •