MySQL Forums
Forum List  »  Oracle

consult about procedure insert clob into db
Posted by: wissam abdallah
Date: February 14, 2014 07:18AM

I would like to be sure about my procedure out put t!! I write the following procedure



phtml (p_airpcode in varchar2, File_Metar OUT CLOB)
AS
req UTL_HTTP.REQ;
resp UTL_HTTP.RESP;
i integer ;
BEGIN
DBMS_OUTPUT.ENABLE(3000000);
req := UTL_HTTP.BEGIN_REQUEST ('http://....................................................................';);
UTL_HTTP.SET_HEADER(req, 'User-Agent', 'IE8');
resp := UTL_HTTP.GET_RESPONSE(req);

USING_CLOB.LOB_INS(1,'Metar_taf', '/' );
LOOP
UTL_HTTP.READ_LINE(resp, File_Metar , TRUE);
p2_putlines(File_Metar );
USING_CLOB.ADD_MORE (1, File_Metar );
USING_CLOB.LOB_INS(1,'Metar_taf', File_Metar );
END LOOP;
UTL_HTTP.END_RESPONSE(resp);


EXCEPTION
WHEN UTL_HTTP.END_OF_BODY THEN
UTL_HTTP.END_RESPONSE(resp);



END;




after the execution l have got the procedure out put :
DOC_ID NAME DOC
----------------------------------------------------------------------------------
1 Metar_taf </TD> </TR>
1 Metar_taf </TR> <TR VALIGN="top">
1 Metar_taf <TR VALIGN="top"> <
1 Metar_taf <TD ALIGN="left"SPAN="2"><FONT
1 Metar_taf <FONTpace,Courier">OLBA 140800Z





is this a logical result??? because i think it should be like this


DOC_ID NAME DOC
------------------------------------------------------------------------------
1 Metar_taf </TD> </TR>
</TR> <TR IGN="top">
<TR
COLSPAN="2">
<TD
Monospace,Courier">OLBA
<FONT

i mean should not the result been without a redundancy in the 2 field DOC_ID by (1 ) and NAME by ( Metar_taf)???



Thank you.

Options: ReplyQuote


Subject
Views
Written By
Posted
consult about procedure insert clob into db
2224
February 14, 2014 07:18AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.