You are here: Foswiki>Main Web>XmlEngine>InsertOperation (revision 3)EditAttach

INSERT Operation

The INSERT operation creates new objects. It inserts the object and its child objects. Newly created IDs are stored in the Response XML.

Example:

Request XML
<request version='1.0'>
  <header>
    <office/>
    <user/>
    <password/>
  </header>
  <insert>
    <Contact>
      <LastName>Ackerman</LastName>
      <FirstName>Joseph</FirstName>
      <MiddleName>M</MiddleName>
      <Title>Dr</Title>
      <TaxID>559658750</TaxID>
      <Person>
        <Dob>1950-02-27</Dob>
        <Gender>1</Gender>
        <Occupation>Medical</Occupation>
        <JobTitle>Chief Of Staff</JobTitle>
        <Marital>1</Marital>
        <Salary>150000</Salary>
      </Person>
      <PreferredPhone>
        <AreaCode>626</AreaCode>
        <Number>5853505</Number>
      </PreferredPhone>
    </Contact>
  </insert>
</request>

Response XML
<response version="1.0">
  <header>
    <sessionClosed/>
  </header>
  <insert>
    <Contact _status="inserted" _type="obj" id="Contact.1.31">
      <PreferredPhone _status="inserted" _type="obj" id="Phone.1.16"/>
    </Contact>
  </insert>
  <_status>OK</_status>
</response>



Edit | Attach | Print version | History: r6 | r4 < r3 < r2 < r1 | Backlinks | View wiki text | Edit WikiText | More topic actions...
Topic revision: 29 Oct 2012, dustin
 

This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback