IncludeDeleted
Specifies whether the provider returns deleted records in the default result set for tables that support deletion tracking.
Data Type
bool
Default Value
false
Remarks
When a query does not include an explicit filter on the deleted column, this property controls whether deleted records are included in the default result set:
- false (the default): The connector returns only non-deleted (live) records.
- true: The connector returns both deleted and non-deleted records.
This property applies to both the DataQuery and AQuADataExport schemas that you select with the ZuoraService property.
Tables that expose the deleted column also expose an IncludeDeleted pseudo-column, which overrides this property for a single query. When the WHERE clause of a query contains IncludeDeleted = true or IncludeDeleted = false, the connector uses that value instead of this property. When no such condition is present, this property applies.
SELECT Id, deleted FROM Account WHERE IncludeDeleted = true AND deleted = trueThe connector honors the pseudo-column only when you compare it to a value with the equals operator and join it to the rest of the WHERE clause with AND. The connector ignores any other form, such as !=, IN, or a condition nested under OR, and applies this property instead.
As with all pseudo-columns, IncludeDeleted appears in the column list only when the PseudoColumns property includes it, for example when you set that property to *=*. You can use it in a WHERE clause regardless of that setting.
Note that Zuora retains deleted data for approximately 30 days, so you can retrieve only recently deleted records.