I run some Oracle procedure with the help of cursor and get output in logfile via dbms_output.put_line.
What I would like to do is break line on server_name, is it possible with dbms_output.put_line?
currently it list everything together which doesn't look tidy.
Also some server id appears as 1234.9 or 1234.88, is it possible to set numformat like 999.99? somehow I can't do col server_id for 999.99
within procedure.
create procedure proc (vServer IN VARCHAR2, vServerID IN NUMBER)
IS
CURSOR curTable
IS
SELECT server_name, server_id
FROM tab1
WHERE server_name = vServer
and server_id = vServerID;
BEGIN
FOR rec1 IN curTable
LOOP
dbms_output.put_line(rec1.server_name || ' '|| rec1.server_id);
END LOOP;
END proc;
Sample required output:
S1 1234
S1 1234
S1 1234
S2 5678
S2 5678