Welcome to Zuora Product Documentation

Explore our rich library of product information

Retrieve custom field definition changes

Learn how to retrieve auditing records of changes to custom field definitions using a data query.

The following use case retrieves the auditing records of changes to custom field definitions.

  1. Submit a data query job through UI or API with the following SQL query:
    SELECT username    AS Username,
           action      AS Action,
           objectname  AS ObjectName,
           attributeid AS Attribute,
           oldvalue    AS OldValue,
           newvalue    AS NewValue,
           timestamp   AS Timestamp
    FROM   auditobjectchangeevent
    WHERE  objecttype = 'CustomFieldDefinition'
           AND year = 2022
           AND month = 11
           AND day > 1
           AND day < 31
    ORDER  BY timestamp DESC 
    LIMIT  100000
  2. Check the status of the query job through UI or Get data query job API operation.
  3. Download the query result when the job is completed. See the following example of the query result.
    Username,Action,ObjectName,Attribute,OldValue,NewValue,Timestamp
    audit-trail@zuora.com,UPDATED,Account.LastReviewDate__c,Required,true,false,2022-11-13T07:50:44.683Z
    audit-trail@zuora.com,CREATED,Account.LastReviewDate__c,Description,,Date of the last business review with the customer,2022-11-13T07:50:22.915Z
    audit-trail@zuora.com,CREATED,Account.LastReviewDate__c,ApiName,,LastReviewDate__c,2022-11-13T07:50:22.915Z
    audit-trail@zuora.com,CREATED,Account.LastReviewDate__c,Required,,true,2022-11-13T07:50:22.915Z
    audit-trail@zuora.com,CREATED,Account.LastReviewDate__c,ReadOnlyOnUI,,false,2022-11-13T07:50:22.915Z
    audit-trail@zuora.com,CREATED,Account.LastReviewDate__c,Type,,Date,2022-11-13T07:50:22.915Z
    audit-trail@zuora.com,CREATED,Account.LastReviewDate__c,Label,,LastReviewDate,2022-11-13T07:50:22.915Z
    audit-trail@zuora.com,CREATED,Account.LastReviewDate__c,MaxLength,,255,2022-11-13T07:50:22.915Z