Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

to reduce code

V prasadOct 20 2010 — edited Oct 20 2010
hi
below is my code

this code is using for output purpose,
here i am using dbms_output stmts a lot,
by using loop condition
can any one try reduce below code..???



DECLARE
P_INPUTXML VARCHAR2(8000);
P_OUTPUTXML CLOB;
P_STATUS VARCHAR2(200);
BEGIN
P_INPUTXML :=
'<InputParameters><ParamSet></ParamSet></InputParameters>';

PAYCODE_PROCE(
P_INPUTXML => P_INPUTXML,
P_OUTPUTXML => P_OUTPUTXML,
P_STATUS => P_STATUS );
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 1, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 241, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 481, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 721, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 961, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 1201, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 1441, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 1681, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 1921, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 2161, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 2401, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 2641, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 2881, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 3121, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 3361, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 3601, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 3841, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 4081, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 4561, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 4801, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 5041, 240));
DBMS_OUTPUT.PUT_LINE(SUBSTR(P_OUTPUTXML, 5281, 240));
DBMS_OUTPUT.PUT_LINE('P_STATUS = ' || P_STATUS);
END ;
This post has been answered by hm on Oct 20 2010
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 17 2010
Added on Oct 20 2010
3 comments
73 views