Solved

Bind Variables Passed from command line to script

Posted on 2009-06-30
3
676 Views
Last Modified: 2013-12-07
I have the following SQL Script

  SET echo off       ;
  SET feedback off   ;
  SET heading off    ;
  SET newpage 0      ;
  SET pagesize 0     ;
  SET underline off  ;
--
SPOOL &1
--
SELECT
       name
FROM   persons p
WHERE  p.id = &2 ;
SPOOL OFF ;

When it's run the contents of the spool file are:
old   4: WHERE  p.id = &2
new   4: WHERE  p.id = 203762
Simon

Can anyone tell me how to suppress the display of the lines
old   4: WHERE  p.id = &2
new   4: WHERE  p.id = 203762
so they don't appear in the output?
0
Comment
Question by:Gaetor
  • 2
3 Comments
 
LVL 73

Accepted Solution

by:
sdstuber earned 500 total points
ID: 24748475
set verify off
0
 

Author Closing Comment

by:Gaetor
ID: 31598479
Excellent, thank you
0
 
LVL 73

Expert Comment

by:sdstuber
ID: 24749022
glad I could help
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Why doesn't the Oracle optimizer use my index? Querying too much data Most Oracle developers know that an index is useful when you can use it to restrict your result set to a small number of the total rows in a table. So, the obvious side…
How to Unravel a Tricky Query Introduction If you browse through the Oracle zones or any of the other database-related zones you'll come across some complicated solutions and sometimes you'll just have to wonder how anyone came up with them.  …
This video shows how to Export data from an Oracle database using the Original Export Utility.  The corresponding Import utility, which works the same way is referenced, but not demonstrated.
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now