Apply Operation Result Cache Policy

Use the apply operation result cache policy to update the consolidated database, based on the results returned by the operation..

The record set that is returned from the operation is processed and applied to the consolidated database.

This example uses the "customer" table, which is in the sampledb database:
  1. Drag and drop the "customer" table onto the Mobile Application Diagram to create a mobile business object.
  2. Double-click the Create operation to open the Operation Properties dialog.
  3. Select the Definition tab, and update the SQL query to:
    INSERT INTO sampledb.dba.customer
    (id,
    fname,
    lname,
    address,
    city,
    state,
    zip,
    phone,
    company_name)
    VALUES
    (@OP["id"=""],
    '@OP["fname"=""]',
    '@OP["lname"=""]',
    '@OP["address"=""]',
    '@OP["city"=""]',
    '@OP["state"=""]',
    '@OP["zip"=""]',
    '@OP["phone"=""]',
    '@OP["company_name"=""]'
    )
    SELECT * FROM customer where id = @OP["id"=""]
    
  4. Select the Cache Policy tab, and select Apply operation result.
  5. Click Apply.
  6. CDb and client data updates are based on the operation definition and the apply operation result policy; other changes to the Enterprise Information System are ignored.