Closed Thread
Results 1 to 4 of 4

Calling Oracle Stored Procedure

Hybrid View

Guest Calling Oracle Stored... 02-08-2006, 05:35 PM
Guest Re: Calling Oracle Stored... 02-08-2006, 08:25 PM
Guest Re: Calling Oracle Stored... 02-09-2006, 09:10 AM
Guest Re: Calling Oracle Stored... 02-09-2006, 09:30 PM
  1. #1
    Jim Heavey
    Guest

    Calling Oracle Stored Procedure

    Well, I am making progress. I have been successful in creating parms for a
    stored procedure and getting a value returned to me. The problem is I
    doctored my Oracle Procedure to return a integer rather then the Ref Cursor
    that I really want to have returned.

    Does anyone know what Type (DataType.Enum) I should be using to get back and
    be able to process a Oracle Ref Cursor?

    Second question. When I use the following command to create a parameter,
    the Intellisense which pops up indicates that the last parameter value of the
    method "Value" is not required, but yet it requires me to enter this amount.
    Since the parameter being created is an output paramter, I do not want to
    place a value in here. How do I enter the command so I do not have to enter
    the optional parameter value?

    cmd.Parameters.Append cmd.CreateParameter("o_Rows", adArray,
    adParamOutput, , 0)

    In this situation I am entering zero, but I do not want to enter anything
    there... If I do not place anything there and close the parenthesis, I get a
    compile error.

    Thanks in advance for your assistance!!!!


  2. #2
    Tim Williams
    Guest

    Re: Calling Oracle Stored Procedure

    Jim,

    I replied in your previous thread....

    -------------
    Are you using a ref cursor as an OUT parameter from a procedure, or as the
    return value from a function?

    I know that if a PLSQL function returns a ref cursor then in VBA you would
    set the return value to an ADO recordset...

    Example here...
    http://www.oracle-base.com/articles/...Recordsets.php

    Tim

    --
    Tim Williams
    Palo Alto, CA


    --
    Tim Williams
    Palo Alto, CA


    "Jim Heavey" <JimHeavey@discussions.microsoft.com> wrote in message
    news:F081297B-2A6C-47D5-9577-A8063B54D045@microsoft.com...
    > Well, I am making progress. I have been successful in creating parms for

    a
    > stored procedure and getting a value returned to me. The problem is I
    > doctored my Oracle Procedure to return a integer rather then the Ref

    Cursor
    > that I really want to have returned.
    >
    > Does anyone know what Type (DataType.Enum) I should be using to get back

    and
    > be able to process a Oracle Ref Cursor?
    >
    > Second question. When I use the following command to create a parameter,
    > the Intellisense which pops up indicates that the last parameter value of

    the
    > method "Value" is not required, but yet it requires me to enter this

    amount.
    > Since the parameter being created is an output paramter, I do not want to
    > place a value in here. How do I enter the command so I do not have to

    enter
    > the optional parameter value?
    >
    > cmd.Parameters.Append cmd.CreateParameter("o_Rows", adArray,
    > adParamOutput, , 0)
    >
    > In this situation I am entering zero, but I do not want to enter anything
    > there... If I do not place anything there and close the parenthesis, I get

    a
    > compile error.
    >
    > Thanks in advance for your assistance!!!!
    >




  3. #3
    Jim Heavey
    Guest

    Re: Calling Oracle Stored Procedure

    Thanks Tim

    As in the example you pointed me to, I am using a Procedure with an OUT parm
    with a type of a Ref Cursor.

    When I attemp to call the procedure without defining the parm for the Ref
    Cursor, I get an Oracle error which indicates the wrong number of paramters
    or the wrong types of parameters was provided.

    So I am not sure why in the example it worked without defining the ref
    cursor parameter, but for me it does not work.

    So close....but so far away....I will keep pluging at it.

    Thanks for your assistance!

  4. #4
    Tim Williams
    Guest

    Re: Calling Oracle Stored Procedure

    Have you considered turning your procedure into a function ?

    --
    Tim Williams
    Palo Alto, CA


    "Jim Heavey" <JimHeavey@discussions.microsoft.com> wrote in message
    news:48DDB2DB-E360-479B-8FCE-36E89382C947@microsoft.com...
    > Thanks Tim
    >
    > As in the example you pointed me to, I am using a Procedure with an OUT

    parm
    > with a type of a Ref Cursor.
    >
    > When I attemp to call the procedure without defining the parm for the Ref
    > Cursor, I get an Oracle error which indicates the wrong number of

    paramters
    > or the wrong types of parameters was provided.
    >
    > So I am not sure why in the example it worked without defining the ref
    > cursor parameter, but for me it does not work.
    >
    > So close....but so far away....I will keep pluging at it.
    >
    > Thanks for your assistance!




Closed Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1