Can we use ampersand in alias names which we use in Oracle select statement. any work around to get this working?
select ename||','||job as name&job from employees ;
ps: I am using plsqldeveloper IDE.
Can we use ampersand in alias names which we use in Oracle select statement. any work around to get this working?
select ename||','||job as name&job from employees ;
ps: I am using plsqldeveloper IDE.
It's entirely possible - you have to put the identifier in quotes, and you also have to turn the substitution prompting off - either by selecting the relevant option in whichever IDE you're using, or by using set define off. E.g.:
set define off;
select dummy "JOB&NAME" from dual;
JOB&NAME
--------
X
Don't forget to set define back on afterwards, if this is part of a script.