Re: Sqlplus and reading in a variable - Help!

From: <rtproffitt_at_my-deja.com>
Date: Fri, 17 Mar 2000 23:58:21 GMT
Message-ID: <8augqs$au0$1_at_nnrp1.deja.com>


Sally,

  1. CREATE OR REPLACE PROCEDURE DIVISION.CliLCBalance AsOfDate;IN DATE) I assume you meant CREATE OR REPLACE PROCEDURE DIVISION CliLCBalance(AsOfDate IN DATE)
  2. The problem is that you are sending a string, but nowhere are there any quote marks. Try changing your script like so: (EOMProcedures.sql) WHENEVER SQLERROR EXIT FAILURE; EXECUTE Division.Create_CliLCBalance('&1'); EXIT SUCCESS;
2a. Alternatively, I suppose you could declare the parameter as

    AsDateStr in Varchar2....
and then use a conversion.
  TheDate := to_date(AsDateStr,'dd-MON-yyyy');   select .....
   where..... = TheDate;

Robert Proffitt
Beckman Coulter
RTProffitt AT beckman DOT com

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Sat Mar 18 2000 - 00:58:21 CET

Original text of this message