That's not quite what he asked for...

Erik, you're looking for the DEFINE command, and you don't really need to
use '&&' either (unless you want to reuse the script without the DEFINE),
e.g.:

define datestamp = "sysdate - 1"

select count(*) from logtab2003
where datestamp = to_char(&datestamp, 'yyyymmdd');

select count(*) from errtab2003
where datestamp = to_char(&datestamp, 'yyyymmdd');

quit

----- Original Message -----
To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]>
Sent: Wednesday, January 15, 2003 10:24 AM



Use && instead of & and you should not get prompted if the variable has a
value set.

-----Original Message-----
Sent: 15 January 2003 15:04
To: Multiple recipients of list ORACLE-L


I am using substitution variables in SQLPlus, but don't want to be
prompted
for their values. I want to set them at the start of the script. Kind of
like a preprocessor directive. Is this possible?

Erik
--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: Erik Williams
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: McBain, Neil  SITI-ITDSEL314
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).


-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Philip Douglass
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to