Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Escaping & in select list

947771Dec 11 2012 — edited Dec 13 2012
Hi

In select list i am making link like
select <a target="_blank" href="pageurl?Id=' || CAST(a.id AS VARCHAR2(30)) || '&xid=3' ||  '">' || CAST(a.id AS VARCHAR2(30))  || '</a>'

from t a
this prompt for input but in SP it does not

i found some solution please suggest me which one i should use.

1)SET DEFINE OFF;
or

2)SET ESCAPE ON;
SELECT 'blah \& blah' AS DES FROM DUAL;

or

3)select 'blah&' || 'blah' from dual;

yours sincerely

Edited by: BluShadow on 11-Dec-2012 13:48
added code tags to the original code to make it readable. Please read {message:id=9360002} and learn to do this yourself.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 10 2013
Added on Dec 11 2012
5 comments
140 views