Oracle Web Services On Demand Guide > Web Services On Demand API Calls > Web Services v2.0 API Calls >

Delete


Removes records of a specified record type from the Oracle CRM On Demand database.

Usage

You use the Delete method to remove one or more records of a particular object from an Oracle CRM On Demand instance.

The deleted records appear in the Deleted Items folder and can be restored through the Oracle CRM On Demand UI.

The Delete call can be used to delete both parent record and child records. If the child node specified in the request is available, it deletes the child in the existing parent record, and leaves the parent record undeleted. However, if the child node is missing, it deletes the existing parent record.

Arguments

Table 31 describes the arguments taken by the Delete method.

Table 31. Arguments Taken by the Delete Method
Name
Description
Required
Default
I/O

ListOf(Object). For example, ListOfAccount

The list of object instances to be deleted.

Yes

Not applicable

Input/Output

LOVLanguageMode

The language mode for picklists, see The LOVLanguageMode Argument.

No

LIC

Input

Echo

Controls whether data sent to Oracle CRM On Demand through integration Web services are recorded as transactions.

No

On

Input

ViewMode

Specifies the level of access to records specified in the method call, see The ViewMode Argument.

No

Broadest

Input

Return Value of the Call

The status key for each of the deleted objects.

Sample SOAP Request - Delete

The following SOAP request contains two contact records, one of which specifies a parent contact record and one of its child account records, while the other only specifies a parent contact record. When a child record is included in the request, the parent record is ignored and only the specified child record is deleted, whereas when no child record is included in the request, the parent record is deleted.

The contact ID is specified as the user key to identify the contact records in the request. See User Key Fields on the Contact Object for a list of valid user key field combinations for the contact object.

<?xml version="1.0" encoding="utf-8" standalone="no"?>

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Header>

<wsse:Security>

<wsse:UsernameToken>

   <wsse:Username>%%USERNAME%%</wsse:Username>

   <wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">%%PASSWORD%%</wsse:Password>

</wsse:UsernameToken>

</wsse:Security>

</soap:Header>

<soap:Body>

<ContactDelete_Input xmlns="urn:crmondemand/ws/ecbs/contact/">

<ListOfContact>

   <Contact>

      <Id>ADSA-96IZCS</Id>

      <ListOfAccount>

         <Account>

            <AccountName>A1</AccountName>

            <AccountLocation>HQ</AccountLocation>

         </Account>

      </ListOfAccount>

   </Contact>

   <Contact>

      <Id>ADSA-96J5ZL</Id>

   </Contact>

</ListOfContact>

</ContactDelete_Input>

</soap:Body>

</soap:Envelope>

Sample SOAP Response

The following SOAP response contains the returned status keys for the deleted objects:

<?xml version="1.0" encoding="utf-8"?>

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<SOAP-ENV:Body>

<ns:ContactDelete_Output xmlns:ns="urn:crmondemand/ws/ecbs/contact/">

<ListOfContact xmlns="urn:/crmondemand/xml/Contact/Data">

   <Contact>

      <ModifiedDate>2011-08-10T15:21:43Z</ModifiedDate>

      <CreatedDate>2011-08-09T21:17:05Z</CreatedDate>

      <ModifiedById>HRZ780-I5RUE</ModifiedById>

      <CreatedById>HRZ780-I5RUE</CreatedById>

      <ModId>4</ModId>

      <Id>ADSA-96IZCS</Id>

      <CreatedBy>Joanne Brown, 08/09/2011 16:17:05</CreatedBy>

      <ModifiedBy>Joanne Brown, 08/10/2011 10:21:43</ModifiedBy>

      <ListOfAccount>

         <Account>

            <ModifiedDate>2011-08-10T14:44:27Z</ModifiedDate>

            <CreatedDate>2011-08-10T14:44:27Z</CreatedDate>

            <ModifiedById>HRZ780-I5RUE</ModifiedById>

            <CreatedById>HRZ780-I5RUE</CreatedById>

            <ModId>0</ModId>

            <Id>ADSA-977GCL</Id>

            <CreatedBy>Joanne Brown, 08/10/2011 09:44:27</CreatedBy>

            <ModifiedBy>Joanne Brown, 08/10/2011 09:44:27</ModifiedBy>

         </Account>

      </ListOfAccount>

   </Contact>

   <Contact>

      <ModifiedDate>2011-08-10T15:22:46Z</ModifiedDate>

      <CreatedDate>2011-08-09T21:13:33Z</CreatedDate>

      <ModifiedById>HRZ780-I5RUE</ModifiedById>

      <CreatedById>HRZ780-I5RUE</CreatedById>

      <ModId>2</ModId>

      <Id>ADSA-96J5ZL</Id>

      <CreatedBy>Joanne Brown, 08/09/2011 16:13:33</CreatedBy>

      <ModifiedBy>Joanne Brown, 08/10/2011 10:22:46</ModifiedBy>

   </Contact>

</ListOfContact>

</ns:ContactDelete_Output>

</SOAP-ENV:Body>

</SOAP-ENV:Envelope>

Oracle Web Services On Demand Guide, Version 23.0 (Oracle CRM On Demand Release 35) Copyright © 2017, Oracle and/or its affiliates. All rights reserved. Legal Notices.