Solved

SQL

Posted on 2011-09-14
6
226 Views
Last Modified: 2012-05-12
HI EXPERTS
select 'iamtechnical & good Morning' from dual

if i execute the above line sql server or toad, a window is popping up for &, to input value.
how to get read of & and : in toad, if it is in a string

0
Comment
Question by:iamtechnical
  • 5
6 Comments
 
LVL 51

Expert Comment

by:HainKurt
ID: 36536349
set scan off;
select 'iamtechnical & good Morning' from dual;

and run as script
0
 
LVL 51

Expert Comment

by:HainKurt
ID: 36536363
in toad options, "execute/Compile" there is an option
"Prompt for substitution variables" uncheck that one and run with F9
0
 

Author Comment

by:iamtechnical
ID: 36536406
@hainkurt

if i run set scan off, i would not be able to call variables when ever necessary

and if i uncheck the box, it will entirely take out the option of SCANNING variables, which i dont want

select 'iamtechnical & good Morning' from dual
where :in_date <= sysdate

in the above line i get two promts
1 for &
1 for :

but i need the : promt not the &

0
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.

 
LVL 51

Expert Comment

by:HainKurt
ID: 36536505
try

set define on;
set esc '\';
select 'iamtechnical \& good Morning' from dual;
0
 
LVL 51

Expert Comment

by:HainKurt
ID: 36536571
or what about this


select 'iamtechnical '|| '&' || ' good Morning' from dual where 1=:x;

it will ask for :x but no other prompt...
0
 
LVL 51

Accepted Solution

by:
HainKurt earned 250 total points
ID: 36536600
or this

set define ':';
select 'iamtechnical & good Morning' from dual where 1=:x;

it will ask for :x but not &good
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

All XML, All the Time; More Fun MySQL Tidbits – Dynamically Generate XML via Stored Procedure in MySQL Extensible Markup Language (XML) and database systems, a marriage we are seeing more and more of.  So the topics of parsing and manipulating XM…
Introduction Since I wrote the original article about Handling Date and Time in PHP and MySQL (http://www.experts-exchange.com/articles/201/Handling-Date-and-Time-in-PHP-and-MySQL.html) several years ago, it seemed like now was a good time to updat…
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …

920 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

16 Experts available now in Live!

Get 1:1 Help Now