POST data using UTL_HTTP

Hi There,
First of all, I am using the UTL_HTTP package for the first time. Basically, we have to POST JSON data to a URL. The format of the data is
{"definition":"Part","item":"Part1","value":"123"}
{"definition":"Part","item":"Part2","value":"789"}
{"definition":"Part","item":"Partn","value":"345"}
Now using the Curl command we can run the comand
$ curl -X POST http://xyz.com/test -H 'Content-Type: application/json' -d '{"items":[
{"definition":"Part","item":"Part1","value":"123"}
{"definition":"Part","item":"Part2","value":"789"}
{"definition":"Part","item":"Partn","value":"345"}The same needs to be implemented in PL/SQL, I found this link
http://technology.amis.nl/2012/01/19/publishing-to-cometd-bayeux-channel-from-inside-the-oracle-database-plsql-based-push-to-cometd-web-client/
I was getting the error
Error report:
ORA-29273: HTTP request failed
ORA-06512: at "SYS.UTL_HTTP", line 1130
ORA-29261: bad argument
ORA-06512: at line 61
29273. 00000 - "HTTP request failed"
*Cause:    The UTL_HTTP package failed to execute the HTTP request.
*Action:   Use get_detailed_sqlerrm to check the detailed error message.
Fix the error and retry the HTTP request.
This was after I tried changing the POST procedure to a anonymoust block and tried to run it since we do not have create rights on the DB. Before I post the change, just wanted to check if anyone has any suggestions on impementing this in PL/SQL, basically, we just need to send 2 columns data in JSON format to a URL on a daily basis.
Thanks

Have a look at the SOAP example in {message:id=4205205}. Posting JSON will be very similar - but instead of a SOAP envelope and header tags, these will be JSON format.
Not sure what response you expect back from the web server. In the case of SOAP, it is XML - so the sample function returns XML.

Similar Messages

  • Any Standard FM  for material stocks on posting date  using  Tcode  MB5B

    Hi,
    I  need   Standard  FM  to get  material stocks on posting date  using   Tcode   :   MB5B
    Stock type  i am using  is  : Storage Location/Batch Stock
    the  Input   i am  providing  is    Material, Plant , Storage Location, selection  date From , selecDate To.
    Then   i need  to get  data  that it  provides   header  and  document  item level.
    Can u please tel me  how do i get  that  material stock data  on posting date and in which tables
    it will be populated in the database.
    ITs required  can u take view and post info
    Thanks & Regards
    sivakumar kasa
    Edited by: siva kumar kasa on Dec 21, 2010 2:30 PM
    Edited by: siva kumar kasa on Dec 22, 2010 7:15 AM

    hi Rehan,
    I have checked all settings also enhancement  but there is no as such control to restrict backposting within current period
    I think its self disipline action not to post backdated GI when GR is done on later date
    Vishal...

  • Adobe form-Able to post  data using Adobe Reader 9 but not with Adobe Proff

    Hello Guru's
    I am facing one problem with adobe forms.
    We have develoed a adobe form using adobe reader 9.
    Now when user are posting the purchase requistion using the form,they are able to post the data using
    Adobe Reader 9 but not with Adobe Reader professional.
    Can anyone please advice me what can be the problem here.

    Adobe Reader 9 can't save the old FDA forms. FDA must update their forms.

  • POST Data Using Javascript

    Hi Guys,
    I ran into this trouble, basically, what I need is to post data into this url using REST:
    www.thissite.com/comment
    now it says:
    do this with a variable name content, containing "key: value" line by line:
    id:
    Action: comment
    Text: the text comment
    now it has a sample on how to do this using java:
    import java.io.IOException;
    import org.apache.commons.httpclient.HttpClient;
    import org.apache.commons.httpclient.methods.PostMethod;
    import org.apache.commons.httpclient.methods.multipart.MultipartRequestEntity;
    import org.apache.commons.httpclient.methods.multipart.Part;
    import org.apache.commons.httpclient.methods.multipart.StringPart;
    public class RtTicketCreator {
    static final String BASE_URI = "http://www.thissite.com/REST/1.0";
    public static void main(String[] args) throws IOException {
    PostMethod mPost = new PostMethod(BASE_URI + "/1234/comment/");
    Part[] parts = { new StringPart("content", "id: 1234\nAction: comment") };
    mPost.setRequestEntity(new MultipartRequestEntity(parts, mPost.getParams()));
    HttpClient cl = new HttpClient();
    cl.executeMethod(mPost);
    System.out.println(mPost.getResponseBodyAsString());
    Now, my question is: Can I do this using javascript? If yes, could you at least give me an idea how to accomplish this?
    Thanks Guys,
    Best Regards,
    Aaron

    Hi Vishvesh,
    Could you please let me know how you resolved the issue.
    I am also developing a web app in eclipse consuming the odata and when checking the script in Firebug i gor the error as
    GET http:/<server>;port/sap/opu/sdata/sap/GURU/$metadata/$metadata?$format=xml 
    00:01:50 2012-04-06 The following problem occurred: HTTP request failed0,, -
    Thanks and regards
    Gururaj

  • Posting data using HTTPClient (Innovation)

    Hi all,
    I have the following problem:
    I'm using HTTPClient library from Innovation.ch and have used the following code to post data to the following website : http://blast.genome.ad.jp/
    import java.io.*;
    import java.applet.*;
    import javax.swing.*;
    import java.util.*;
    import java.awt.*;
    import HTTPClient.*;
    public class VistaConnection {
      private String sequence;
      private String str;
      private String resultURL;
      public VistaConnection(String seq) {
        sequence = seq;
        try{
          URI doc_url = new URI ("http://blast.genome.ad.jp");
          URI form_url = new URI (doc_url,"/sit-bin/nph-blast");
          HTTPConnection con = new HTTPConnection(form_url);
          NVPair[] form_data =
              new NVPair[] {
                  new NVPair("prog", "blastn"),
                  new NVPair("dbname", "nr-nt"),
                  new NVPair("V_value", "500"),
                  new NVPair("B_value", "250"),
                  new NVPair("sequence", sequence),
                  new NVPair("filter", "F"),
          HTTPResponse resp = con.Post(form_url.getPathAndQuery(), form_data);
          String Output = "";
          if(resp.getStatusCode () >=300){
            System.err.println("Received Error:"+ resp.getReasonLine());
            //System.err.println(resp.getText());
          else {
            DataInputStream input = new DataInputStream(resp.getInputStream());
            resultURL = "";
            while(null != ((str = input.readLine()))){
              System.out.println(str);
              Output += str;
            input.close();
        }catch(IOException ioe){
          System.err.println(ioe.toString());
        }catch (ParseException pe) {
          System.err.println("Error parsing Content-Type: " + pe.toString());
        } catch (ModuleException me) {
          System.err.println("Error handling request: " + me.getMessage());
    }when I run this code in my program the data gets posted but I cannot retreive the results because they are loaded up in separate web page,
    I was Hoping that someone would be able to give me some Idea of how to retreive these results from the server through my code.
    Thanks for any help
    P.S. Just in case I've added the data that I post through my program below:
    gi|23821530|dbj||SEG_D10989S Bos taurus gene for endothelin receptorGGGATCCCGAGCAAACTGCGGAGGCCACACTGTCAGGCATTCCCTCGGCGTTTCGTCAGAGCCAGACCCT
    CCCGCTGCTGAAGGGAGGCGCGCTCTGCTCCCGGGCTGCCGGGAACCCAGCCGCGCGCCGGGGAAGGAGG
    TCCCTGCCTGGTGCGTCCGGACCAAGAGGTAACCGTTCTGCTTGGTGTTTAATTCAAATCTGTGATTGAA
    CCTTATCCTGGGGCTTCAGTTTGGATTACTTCTTAGGTTTGTTTTTGTTTGTTTGTTTGTTTTTTAACCT
    GTAGCTACAGCAGATTAAAATGGGATTGGAGTGAAGGAGAGGGCTTGAGTGTCTGAAGTCACTCGAAGGG
    GATAGAAACTTCCGAGTTAATCCAGATAGAGACTCTTCCAAATAGACCAAGTGGAGATGTCCGGGAGATT
    TTCCGAGTCAGCCGGCTCAGTCCTGGGGTGTGTGTATGGGGGGTGGGGGCGGTGCCGAAGAGCGGAAGGA
    AGGGGTCTGAAAGTCCAGACATGCGGCATCCGGGGTTGCTGTGGAGTCGAAAGCAGAGACTGGCGATGCC
    CTTGATCTCTAACCTGCCTTGATTTGCCCCGTCCCCGCGCGCCCTTGGCCAGAACGAATACTGCTCCCTC
    TGCGCACACCAGGAGCTCAAAGCTTTGCTTTGGACACCCGTCCTCTCCTCCCCGTCACACCCCTTCCAGG
    ATACCCCGCCCCACTGCGAGTCATTTACCCCTCAGGGGACGCAGGGGAGGAAAAACCAGCGAAAGCTGGC
    TCTGGAGGGACGGTCTAGGGGCGCAAGCGAGTCCCACGCGCCAGAGTTCCCCACTCCCGCGCCAGCTCGA
    CTTATTAATACTTTTGCGCACTGAGAGTGCGGGCGCTGCTGCGCTTGAGGATAGCGGCTTGCAGGGGCGT
    GGCTGGGGACGCTGACCCGGGTGTCCTGTCTTCCTTCCCTTGCTGGTCTCTAGACTCGGAAAGCGGAGGA
    GCGGCCACCCGACTCCCTCTGGAGCAGGCAGCAGCATGCAGCCGCTGCCCAGCTTGTGCGGACGCGCCCT
    GGTGGCGCTGATCCTTGCCTGCGGCGTGGCGGGGATCCAAGCAGAAGAGAGGGAATTCCCGCCAGCCGGG
    GCCACTCAGCCACTTCCGGGGACCGGAGAGATGATGGAGACCCCGACTGAGACCTCCTGGCCCGGGAGGT
    CCAACGCCAGCGACCCGCGATCGTCCGCAACACCGCAGATTCCTAGAGGGGGAAGGATGGCGGGAATCCC
    ACCGCGCACCCCACCCCCGTGCGATGGACCCATAGAGATCAAGGAGACTTTCAAGTACATCAACACGGTG
    GTGTCCTGCCTAGTGTTCGTGCTGGGCATCATCGGAAACTCCACGCTACTGAGAATCATTTACAAGAACA
    AGTGCATGCGAAACGGTCCAAATATCTTGATAGCCAGCCTGGCTCTCGGAGACCTGCTGCACATTATCAT
    TGATATCCCCATCAATACCTACAAGGTAAGGGGTGCCCTG
    CCACTAAGTATACATACAGGTTCAAGAGCACCCTGTGAACATCTCCCTAACAGAGCTCTGTGTCTCCTCA
    ATGCAGCTGCTTGCCAAGGACTGGCCCTTTGGGGTTGAGATGTGTAAGCTGGTGCCTTTCATTCAGAAGG
    CCTCCGTGGGCATCACTGTGCTGAGTCTATGTGCTCTAAGTATTGACAGGTAAGAGCAAGTATCTAAGCG
    ACATATATCCTGACCACGATCCTAGTGCTTGCTACGTTACTTAGAAAGTAAACTGTAATTCAATAAAAAC
    CAGGCTCTGCCAGCTTGGCAATTGATTCTGTTTTGTTCTTCAGATATCGAGCTGTTGCTTCTTGGAGTCG
    GATTAAAGGAATCGGGGTTCCAAAATGGACAGCAGTAGAAATTGTTTTAATTTGGGTGGTCTCCGTGGTT
    CTGGCTGTCCCTGAGGCTGTGGGTTTTGATATAATTACCAGTGATCACATAGGAAATAAACTGAGAATCT
    GCTTGCTCCATCCCACTCAGAAAACAGCATTTATGCAGGTAAATTTTACTTTTTTTTTCCCT
    TCCCCCATAGTTTTACAAGACAGCTAAAGACTGGTGGCTATTTAGTTTCTATTTCTGCCTGCCGCTGGCC
    ATCACTGCATTGTTTTATACCCTGATGACTTGTGAAATGTTGAGAAAGAAGAGTGGTATGCAAATTGCCT
    TAAATGATCACTTAAAACAGGTAAGG
    TTTATTTCAGAGACGGGAAGTGGCCAAAACAGTATTTTGCCTGGTCCTTGTCTTTGCTCTGTGTTGGCTT
    CCTCTTCATCTTAGCAGGATTTTGAAGCTCACTCTTTATGATCAGCATGATCCCCGTAGATGTGAATTTT
    TAAGGTAAGT
    ATAAATAAATTTTCATATTATTTTTGCAGCTTTTTGTTGGTATTGGACTACATTGGCATCAACATGGCCT
    CCCTGAATTCCTGTATTAACCCAATAGCTCTGTATTTGGTGAGCAAAAGATTCAAAAACTGCTTTAAGGT
    AAGACAGTATCGAAAATCAAAA
    TGGTGAGCAAGGAGGGTTGTGATAGTGTAACTTGATGTAAACTTATAACGAAGTTACTTTGCTTTGTGCA
    GTCATGTTTATGCTGCTGGTGCCAATCATTTGAAGAAAAACAGTCCTTGGAGGAAAAGCAGTCGTGCTTA
    AAGTTCAAAGCTAACGATCACGGATATGACAACTTCCGTTCCAGTAATAAATACAGCTCATCTTGAAAGA
    AGGATTATTCATTTTCTTTATTTTGGACAGAAATCATTCAAACAAAGAGGTATCTGTCAAAGTAAAACAA
    AACAACGTGTGTGTTTGCACAAAACAATGTACAAATGTAAGAGTGATTATTTTCTTCACACTCAAGAGTT
    CCACATGACGTTTGATGAGCTGTTTCCAGCATGAGAAGACAAGCAGTGAGAATTAAGAAAGCCTTATTGT
    GAAAGCACTTAATTCTTTTACAGTTAGCACTTCACTATATTATAGCTCTTCAGAACTTCGGTCTATTCAT
    ACACCACTTACATTTAACTTGAGTTCACTCA

    Well, can't actually test this (don't have unproxied access to the internet today) but strikes me this should work.
    It doesn't use the library you use because it just isn't required for something as simple as this.
    Just run as it is and the web server should return an error because the sequence is invalid, then try again with your data.
    Good luck.
    import java.io.InputStream;
    import java.io.ByteArrayOutputStream;
    import java.net.URL;
    import java.net.HttpURLConnection;
    class Sjohri1
         public static void main(String argv[])
              throws Exception
              String sequence= "whatever"; // your sequence goes here
              String szUrl= "http://blast.genome.ad.jp/sit-bin/nph-blast";
              szUrl += "?prog=blastn";
              szUrl += "&dbname=nr-nt";
              szUrl += "&V_value=500";
              szUrl += "&B_value=250";
              szUrl += "&sequence=" +sequence;
              szUrl += "&filter=F";
              URL url= new URL(szUrl);
              HttpURLConnection urlConn= (HttpURLConnection) url.openConnection();
              InputStream in= urlConn.getInputStream();
              ByteArrayOutputStream out= new ByteArrayOutputStream();
              for (int ch; (ch= in.read()) >= 0;)
                   out.write(ch);
              System.out.println(out.toString());
    }

  • POST data using XML

    hi everyone...i want to upload a video to youtube from my desktop application. i went through the following link.
    http://code.google.com/apis/youtube/2.0/developers_guide_protocol_resumable_uploads.html#Sending_a_Resumable_Upload_API_Request
    it is for sending data using XML. but i don't know how to send data using XML. can someone give me an insight of data POST'ing using XML? any help is appreciated.

    actually i saw the following segment in this link :
    http://code.google.com/apis/youtube/2.0/developers_guide_protocol_resumable_uploads.html#Sending_a_Resumable_Upload_API_Request
    POST /resumable/feeds/api/users/default/uploads HTTP/1.1
    Host: uploads.gdata.youtube.com
    Authorization: AuthSub token="DXAA...sdb8"
    GData-Version: 2
    X-GData-Key: key=adf15ee97731bca89da876c...a8dc
    Content-Length: 1941255
    Slug: my_file.mp4
    Content-Type: application/atom+xml; charset=UTF-8
    <?xml version="1.0"?>
    <entry xmlns="http://www.w3.org/2005/Atom"
      xmlns:media="http://search.yahoo.com/mrss/"
      xmlns:yt="http://gdata.youtube.com/schemas/2007">
      <media:group>
        <media:title type="plain">Bad Wedding Toast</media:title>
        <media:description type="plain">
          I gave a bad toast at my friend's wedding.
        </media:description>
        <media:category
          scheme="http://gdata.youtube.com/schemas/2007/categories.cat">People
        </media:category>
        <media:keywords>toast, wedding</media:keywords>
      </media:group>
    </entry>

  • Problem in Posting data using BAPI_ACC_DOCUMENT_POST

    Hi ,
    I am trying to post a Sub-ledger account using the BAPI_ACC_DOCUMENT_POST.
    The Details I am passing are
    DOCUMENTHEADER
    USERNAME  -        UPPUVID
    COMPANY CODE - 1030
    DOC_DATE -           2/2/2009 
    PSTNG_DATE-        2/2/2009
    FISCAL YEAR-        2009
    PERIOD -                02
    DOC TYPE -            DR
    ACCOUNTGL
    ITEMNO_ACC   0000000002
    GL_ACCOUNT  230400   
    PROFIT_CTR    110001          
    ACCOUNTRECEIVABLE
    ITEMNO_ACC     0000000001
    CUSTOMER       40000087
    GL_ACCOUNT   110100  
    CURRENCYAMOUNT
    ITEMNO_ACC       CU CURRE CUR AMT_DOCCUR 
    0000000001          USD                    1,000.0000 
    0000000002          USD                    1,000.0000-
    The result shown is as follows.
    Document posted successfully: BKPFF 180001511510302009 DV1CLNT200 
    But when we go and check in FB03 .
    I am getting an error message saying Document doesnot exist for the Tcode 1030 .
    Also there is no corresponding entry in BKPF .
    Please let me know If I have to pass anything else to post the  data.
    Regards,
    Vidyulatha U.

    Hi Vidyulatha,
    You can also use FM : POSTING_INTERFACE_START & POSTING_INTERFACE_DOCUMENT & POSTING_INTERFACE_END.
    As you know you can post all types of documents through FB01.
    You can set the i_tcode as 'FB01' & i_sgfunct as 'C'.
    You just Pass on the values to these FMs.
    Edited by: Yogesh Karanjikar on Feb 2, 2009 10:55 AM
    Edited by: Yogesh Karanjikar on Feb 2, 2009 10:56 AM

  • Error in Posting Data Using ABAP Program.

    I am Using Scenario SAP(RFC) to Webservice through XI
    I called My RFC into ABAP Program  and given RFC Destination
    and executing it goes into Short DUMP.
    I gives an Error message as
    " alternativeServiceIdentifier:party/service from channel configuration are not"
    Wat should i Do for this Error.
    regards,
    Jayasimha Jangam

    Hi
    Please look into these threads
    alternativeServiceIdentifier: party/service from channel configuration are.
    Rfc sender problem(sap r/3 -se37) 'alternativeServiceIdentifier: party/serv
    Also this Blog will help you,
    /people/michal.krawczyk2/blog/2005/09/07/xi-why-dont-start-searching-for-all-errors-from-one-place
    Reward points if found usefull............

  • POST data using getURL

    One CFFORM with two or three or four... butons.
    I would like to post the form fields to different cfm files
    (as we do with Javascript : document.form.action='myfile.cfm').
    Could somebody show me an example with the getURL ActionScript
    command and the POST method ?
    Thanks for your help.

    actually i saw the following segment in this link :
    http://code.google.com/apis/youtube/2.0/developers_guide_protocol_resumable_uploads.html#Sending_a_Resumable_Upload_API_Request
    POST /resumable/feeds/api/users/default/uploads HTTP/1.1
    Host: uploads.gdata.youtube.com
    Authorization: AuthSub token="DXAA...sdb8"
    GData-Version: 2
    X-GData-Key: key=adf15ee97731bca89da876c...a8dc
    Content-Length: 1941255
    Slug: my_file.mp4
    Content-Type: application/atom+xml; charset=UTF-8
    <?xml version="1.0"?>
    <entry xmlns="http://www.w3.org/2005/Atom"
      xmlns:media="http://search.yahoo.com/mrss/"
      xmlns:yt="http://gdata.youtube.com/schemas/2007">
      <media:group>
        <media:title type="plain">Bad Wedding Toast</media:title>
        <media:description type="plain">
          I gave a bad toast at my friend's wedding.
        </media:description>
        <media:category
          scheme="http://gdata.youtube.com/schemas/2007/categories.cat">People
        </media:category>
        <media:keywords>toast, wedding</media:keywords>
      </media:group>
    </entry>

  • How to use method POST to send XML using utl_http?

    Hi,
    I am trying to work out how to use the POST method to mimic submitting data from a HTML form, using utl_http.
    I cannot use SOAP for this as the people I am sending the data to are just expecting an XML document to be sent to a standard CGI script running on their web server.
    There is a lot of documentation on how to submit data using the POST method (using Utl_Http.Write_Text etc), but I cannot find anything that tells me how to submit form variables.
    The examples on OTN say this:
    "Alternatively use method => 'POST' and Utl_Http.Write_Text to
    build an arbitrarily long message"
    but don't tell me how to actually place the data into the required input parameters of the CGI program I am hitting.
    I need to hit a URL such as
    www.asite.com/cgiprogram
    and pass in a parameter, eg
    in_param="test+data"
    I am currently doing this as a GET, which works, but the XML document I am passing in could potentially be bigger than the GET method will allow.
    Any help would be greatly appreciated.
    Thanks,
    Leon.

    Please try the PL/SQl forum

  • Use FI Posting date as a filter value, can I get YTD for current year?

    Dear Expert,
    I work on a BI report which calculate the YTD key figure (restricted by 0CYEAR and =< 0CMONTH).
    One of the requirement for the report is to allow user to enter a value for a date using FI Posting date (although this is optional).
    Without entering the value for FI Posting date, my report works fine.
    But once FI Posting date is entered, no data found.
    I expect that when the value for the FI Posting date is entered, the YTD value will be calcuated starting from the Jan 1 of that FI Posting year to the FI Posting date entered.
    But this seems not happen.
    Could you help me to resolve this problem?
    If there is a better solution, please let me know.
    Very appreciated.
    Arthur

    Hi Dipika,
    Thanks for your reply.
    In my report, FI Posting date is a free characteristic, which user can optionally select it and fiter it for a specific FI Posting Date. Do you consider it as a global filter?
    my query structure is as below:
    rows: profit center, department, manager
    columns: YTD for current year, YTD for Previous year, the difference betwwen the two
    The requirement is when user enter a FI Posting date, use it  to restrict the KF shown above.
    For example, if the FI posting date is March 15, 2008, then YTD for current year should be restricted by the period between Jan 1, 2008 and March 15, 2008 and YTD for previous year should be restricted by Jan 1, 2007 and March 15, 2007.
    Do you have any idea how to implement this requirement in term of FI Posting date?
    Thanks and appreciated.
    Arthur

  • Using UTL_HTTP

    Hi ...
    I am using oracle 9i release 2 ....
    I want to use UTL_HTTP package to POST the Data ....
    Can Anyone Plz give me the hint of how to use it .....
    I am also worried abt testing the above problem ... Is there anything on Internet to Test the Posting of DATA using UTL_HTTP ....
    Thanks,

    Hi,
    Did you see this sample code below ?
    http://www.oracle.com/technology/sample_code/tech/pl_sql/htdocs/x/Utl_Http_Package_Enhancements/Cr_Using_Utl_Http.htm
    Cheers

  • Can I change the posting date in CO13 to cancel a confirmation?

    Hi all
    I'd like to know how can I change the posting date using CO13.
    So I have a confirmation in date 30/6 for exemple, but I'd like to cancel it in posting date 1/7, but the systems takes the date of the original confirmation. Can I change it any way?
    Thanks in advance
    Points will be given

    Dear Roger,
    this is only possible in case if the bookin periode is closed. In this case it's allowed to change the booking date in CO13 and the date field gets automatically inputable, normaly it's greyed out.
    As long as the booking periode is open, the system automatically use the date from confirmation.
    Hope this help.
    Regards,
    Sabine

  • Problem posting data with HttpsConnection

    Hi,
    I am currently having problems posting data using a HttpsConnection.
    I am setting the setRequestMethod to HttpConnection.POST and then using the openDataOutputStream method.
    I will post my code when I get home for reference.
    Background to my problem - I am trying to use the declarative security features of J2EE to authenticate a mobile user.
    I am firstly firing a HttpsConnection from the mobile device to a protected resource on the app server. I grab the JSessionId from the Set-Cookie http header of the response and post a second request to the j_security_check and provide the refer http header to the protected resource - this simulates exactly what happens on a browser (I used a Http monitor tool to confirm this). However, I need to pass the j_username and j_password as body of the https request. This doesn't seem to work because the server displays my access denied at this point - as if it hadn't received the crednetials
    However, just to confirm my technique works I subsituted the post request for a get request to j_security_check and passed the j_username and j_password as request params in the URL. This worked fine and I got a 302 response 'temporily moved' which I then handle by simply making a further request for the original resource - this time it serves back the resource because I am authenticated.
    Anyway that sets the scene - so the problem definitely appears to be posting data using an HttpsConnection.
    Any help would be greatly appreciated
    Rgds,
    David

    Hi,
    Here is my code relating to the above problem:
    httpsConn = (HttpsConnection)Connector.open("https://127.0.0.1:8443/ebank/j_security_check");
                httpsConn.setRequestMethod(HttpConnection.POST);
                httpsConn.setRequestProperty("referer", "https://127.0.0.1:8443/ebank/main/mainMenu.xml");
                httpsConn.setRequestProperty("cookie", cookieValue);
                httpsConn.setRequestProperty("location", url);
                httpsConn.setRequestProperty("User-Agent",
                    "Profile/MIDP-1.0, Configuration/CLDC-1.0");
                httpsConn.setRequestProperty("Content-Language",
                    "en-gb");
    String credentials = "j_username=EB0001&j_password=240589";
                httpsConn.setRequestProperty("Content-Length",""+credentials.length());
                DataOutputStream os = httpsConn.openDataOutputStream();
                os.writeUTF(credentials);
    ....Thanks,
    David

  • Can we post data 32KB using utl_http package?

    I was using utl_http package for posting http data. Now there is a change in requirement and I have to call a web service instead of normal http post. Also the amount of data to be transferred now is >32KB (previously it was only 16KB). I have to manaually create the SOAP message and post it as http requset. Is it possible to post data more than >32KB using the utl_http package?
    -Kumar
    Message was edited by:
    user586950

    did a trace route and this is what it came out with
    Microsoft Windows XP [Version 5.1.2600]
    (C) Copyright 1985-2001 Microsoft Corp.
    C:\Documents and Settings\Moroni>ping 64.124.140.30:9090
    Ping request could not find host 64.124.140.30:9090. Please check the name and t
    ry again.
    C:\Documents and Settings\Moroni>tracert 64.124.140.30:9090
    Unable to resolve target system name 64.124.140.30:9090.
    C:\Documents and Settings\Moroni>tracert 64.124.140.30
    Tracing route to 64.124.140.30.mfnx.net [64.124.140.30]
    over a maximum of 30 hops:
    1 13 ms 15 ms 33 ms 73.91.188.1
    2 9 ms 11 ms 9 ms GE-2-45-ur01.troutdale.or.bverton.comcast.net [6
    8.87.218.185]
    3 * 12 ms * te-9-3-ar01.troutdale.or.bverton.comcast.net [68
    .87.216.89]
    4 39 ms 13 ms 16 ms 12.116.25.33
    5 17 ms 17 ms 18 ms tbr1011401.st6wa.ip.att.net [12.122.111.6]
    6 17 ms 15 ms 16 ms 12.122.86.41
    7 * * * Request timed out.
    8 * * * Request timed out.
    9 * * * Request timed out.
    10 * * * Request timed out.
    11 * * * Request timed out.
    12 * * * Request timed out.
    13 * * * Request timed out.
    14 * * * Request timed out.
    15 * * * Request timed out.
    16 * * * Request timed out.
    17 * * * Request timed out.
    18 * * * Request timed out.
    19 * * * Request timed out.
    20 * * * Request timed out.
    21 * *

Maybe you are looking for

  • Freeze Spreadsheet header in Web Analysis Report (HTML format)

    Hello, I want to know if there is any way to freeze the spreadsheet header in Web Analysis. I know it can be done if the report is opened through Web Analysis Studio. However, when the user opens it in HTML format, the header will not be freeze. We a

  • To write a perl script for running a java program from cgi of web server

    I have to write a perl script to call a java program(.exe).I want to run this file through the cgi of the web server. java myprogram can anyone help me to write a perl script??

  • Doubt about table locks

    i have a master table from which many other child tables take data for various summarizations. I have a cron tab in unix which calls oracle stored procedures to populate each of these tables in a sequential manner. For example table 1 starts getting

  • Audit WMI Repository. Record all namespace removal events.

    Hello, Every night some of the namespaces in my WMI repository are removed by an unknown source. I have enabled WMI auditing and "Other object access events" in order to populate the security log with WMI access events. The unfortunate thing is that

  • Dreamweaver CS6 crashes constantly when putting with SFTP

    When putting files to the SFTP server that we use hosted by an outside host, we get constant crashes. After program restart, there is no issue with uploading. But wait a few minutes and you can see the SFTP process start, the screen prompt kinda free