Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> UTL_HTTP Post status code 100
Hi,
I am trying a post using UTL_HTTP package on oracle 9i version 2. Here is the code of stored procedure:
env varchar2(100);
req utl_http.req;
resp utl_http.resp;
value VARCHAR2(1024);
NAME VARCHAR2 (255);
v_msg VARCHAR2 (80);
vsend_msg VARCHAR2 (20) := 'ASDASFSFSFFS';
BEGIN
utl_http.set_proxy(xxx.xx.xx.xx', null);
utl_http.set_persistent_conn_support(FALSE);
req := utl_http.begin_request('http://news.com.com/2547-1_3-0-20.xml','POST');
utl_http.set_header(req, 'User-Agent', 'Mozilla/4.0'); utl_http.set_header(req,'Content-Type', 'text/html'); utl_http.set_header(req,'Accept-Language','en-us'); utl_http.set_header(req,'Content-Length',to_char(length(vsend_msg))); utl_http.write_text(req,vsend_msg);
resp := utl_http.get_response(r => req);
dbms_output.put_line('HTTP response status code: ' ||
resp.status_code);
dbms_output.put_line('HTTP response reason phrase: ' ||
resp.reason_phrase);
FOR i IN 1 .. Utl_Http.get_header_count (resp)
LOOP
Utl_Http.get_header (resp,i, NAME => NAME, VALUE =>
VALUE);
DBMS_OUTPUT.put_line (NAME || ': ' || VALUE);
END LOOP;
BEGIN LOOP Utl_Http.read_text (r => resp, DATA => v_msg); DBMS_OUTPUT.put_line (v_msg); END LOOP; EXCEPTION WHEN Utl_Http.end_of_body THEN NULL;
HTTP response status code: 100
HTTP response reason phrase: Continue
Server: Microsoft-IIS/5.0
Date: Wed, 05 Jan 2005 12:34:45 GMT
PL/SQL procedure successfully completed.
I expect an xml string from the URL and manually checked it by making a html form.
Could anyone please guide me as to why the xml string is not being returned to the stored procedure ?
Thanks for any help or pointers. Received on Wed Jan 05 2005 - 07:15:05 CST
![]() |
![]() |