I do not know sqlplus. But trying to complete one task at work. The task is to logon to a schema and get following information in single line - schema_name, database_name, database_link_name, user_name
I am able to get that information in TWO lines. I will be grateful if somebody suggests a simple way of getting results of two different select queries in a single line.
Following works but gives me required results in TWO lines. I want them in single line.
SQL> select * from
(select user || ' ' || sys_context('USERENV','DB_NAME') as Instance from dual),
(select DB_LINK || ' ' || username from user_db_links);
TSTSCRIPT2 ORADEV
MCCODEVTOMCCOSTG_TSTSCRIPT1 TSTSCRIPT1