Want to get rid of Google Ads, click here.
+ Reply to Thread
Results 1 to 2 of 2

Thread: How to retrieve a specific attachment from an incident using Web Services

  1. #1
    Junior Member
    Join Date
    May 2010
    Posts
    1

    Default How to retrieve a specific attachment from an incident using Web Services

    I've been able to retrieve an incident with all its attachments, it all works great.
    A request like below does that work perfectly and Service Manager returns all the attachments together with the incident.
    ________________________________________
    <?xml version="1.0" encoding="UTF-8"?>
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
    <soapenv:Body>
    <ns2:RetrieveIncidentRequest xmlns:ns2="http://schemas.hp.com/SM/7" attachmentInfo="true" attachmentData="true" ignoreEmptyElements="true">
    <ns2:model>
    <ns2:keys>
    <ns2:IncidentID type="String" mandatory="false" readonly="false">IM0000000123</ns2:IncidentID>
    </ns2:keys>
    </ns2:model>
    </ns2:RetrieveIncidentRequest>
    </soapenv:Body>
    </soapenv:Envelope>
    ______________________________

    Nevertheless, I am looking for a solution in getting one specific attachment by its ID.
    I've been trying to do this with messages like below but the Service Manager doesn't return the content of the attachment but all the metadata of the incident, including attachment information, but no contents.
    __________________________
    <?xml version="1.0" encoding="UTF-8"?>
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
    <soapenv:Body>
    <ns2:RetrieveIncidentRequest xmlns:ns2="http://schemas.hp.com/SM/7" attachmentInfo="true" attachmentData="true" ignoreEmptyElements="true">
    <ns2:model>
    <ns2:keys>
    <ns2:IncidentID type="String" mandatory="false" readonly="false">IM0000000793</ns2:IncidentID>
    </ns2:keys>
    <ns2:instance>
    <ns2:attachments>
    <attachment xmlns="http://schemas.hp.com/SM/7/Common" contentId="4c17a7b2cb930041a13143a8"/>
    </ns2:attachments>
    </ns2:instance>
    </ns2:model>
    </ns2:RetrieveIncidentRequest>
    </soapenv:Body>
    </soapenv:Envelope>
    ____________________________

    Any help?

    Thanks.


    Tom

  2. #2
    Junior Member
    Join Date
    Oct 2009
    Posts
    9

    Default

    Hi tomdegetel:


    What about a join between probasummary and SYSATTACHMENTS tables?

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Tags for this Thread

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts