Home » Other » Client Tools » printing spaces before text in sqlplus editor
printing spaces before text in sqlplus editor [message #183452] Fri, 21 July 2006 00:55 Go to next message
indraneelkumar
Messages: 24
Registered: September 2005
Location: bangalore
Junior Member

Hi,
   I want print '      hai' in SQLPLUS.
   But that editor is truncating spaces before text and it
   is printing like 'hai'.
   Thanks in advance.
 
Re: printing spaces before text in sqlplus editor [message #183478 is a reply to message #183452] Fri, 21 July 2006 02:28 Go to previous messageGo to next message
rajavu1
Messages: 1574
Registered: May 2005
Location: Bangalore , India
Senior Member

Not sure about your query ..

SQL> select 'Hello' from dual;

'HELL
-----
Hello

SQL> select '  Hello  ' from dual;

'HELLO'
---------
  Hello

SQL> select '  Hello  world ' from dual;

'HELLOWORLD'
---------------
  Hello  world


Thumbs Up
Rajuvan.
Re: printing spaces before text in sqlplus editor [message #183495 is a reply to message #183478] Fri, 21 July 2006 03:10 Go to previous messageGo to next message
indraneelkumar
Messages: 24
Registered: September 2005
Location: bangalore
Junior Member

Hi
Thanks for reply.
Not through SQL statement.

SQL> EXEC DBMS_OUTPUT.PUT_LINE('       HAI');
HAI

PL/SQL procedure successfully completed.

Here I want to get output as 
SQL>         HAI.

Once some where I saw one statement like
set serveroutput on [set spaces or null]  like this

for the past 2 day I searched in this site. But no luck.

plz help me

Thanks
Re: printing spaces before text in sqlplus editor [message #183498 is a reply to message #183495] Fri, 21 July 2006 03:16 Go to previous message
Maaher
Messages: 7065
Registered: December 2001
Senior Member
SQL> set serverout on format wrapped
SQL> exec dbms_output.put_line('   xxx');
   xxx


MHE
Previous Topic: how to connect database through toad
Next Topic: how to run a PL/SQL program in Toad
Goto Forum:
  


Current Time: Thu Apr 18 08:43:42 CDT 2024