Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> How to return variable

How to return variable

From: Andrew <vanhao_at_fau.campus.mci.net>
Date: Mon, 12 Oct 1998 23:40:18 -0700
Message-ID: <6vus3a$2jp$1@news.campus.mci.net>


Greetings,

I'm using VB and ADO to retrieve a calculated varible from Oracle. The SQL statement is as follow

Declare

    v_NextSequence Number;
Begin

  1. Retrieve the next sequence number for a table;
  2. Use the next sequence number to insert a new record;
  3. ??? I would like to return the v_NextSequence variable to the VB client. This is where I can't figure out. ???; End;

I tried "Return v_NextSequence;" but got an error indicating that an expression can't be used with Return. I didn't compile this routine as an Oracle stored procedure because one of the requirements is that all SQL must be sent through VB/ADO this way.

Please help. Many thanks in advance.
Andrew.
vanhao_at_yahoo.com Received on Tue Oct 13 1998 - 01:40:18 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US