Tuesday, 23 October 2012

How to add new lines in oracle pl/sql

 

​​We can add new lines in plsql by using  ​
DBMS_OUTPUT.PUT ( CHR(10));​


Exapmle:​
SQL> set serveroutput on;
declare
c1 number;
c2 number;

begin

select count(*) into c1 from dba_users;
select count(*) into c2 from dba_objects;

DBMS_OUTPUT.PUT ( CHR(10));
DBMS_OUTPUT.PUT ( CHR(10));
DBMS_OUTPUT.PUT ( CHR(10));

DBMS_OUTPUT.put_line('****** ********************** *****');
dbms_output.put_line('USERS:> '||c1);
dbms_output.put_line('OBJECTS:> '||c2);
DBMS_OUTPUT.put_line('****** ********************** *****');

end;
/

*****************

No comments:

Post a Comment