> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://zuora.ferndocs.com/_mcp/server. # Export ZOQL > Learn how to use Zuora Export ZOQL to create data source exports through the Zuora API, offering powerful querying capabilities for related business objects. Learn how to use Zuora Export ZOQL to create data source exports through the Zuora API, offering powerful querying capabilities for related business objects. Zuora Export ZOQL (Zuora Object Query Language) is the query language you use to create data source exports through the Zuora API. Export ZOQL is more powerful than ZOQL because Export ZOQL queries can select data from related business objects in a single operation. You can perform Export ZOQL queries in the following ways: * Use the AQuA API (recommended) You can use this method to perform multiple queries or continuously query data. * Use the "CRUD: Create Export" API operation You can use this method to create an Export object corresponding to a single query. * Create an Export object through the SOAP API(deprecated) ## Overview of Queries When you write an Export ZOQL query, you must specify the data source to select data from. Each data source provides all your business objects of a particular type. Most data sources also provide related business objects. This saves you the effort of constructing nested queries, and results in better performance. For example, the Invoice Item data source provides every Invoice Item object in your Zuora tenant, along with related Account, Contact, Invoice, Product, Rate Plan, and Subscription objects. ## Names in Queries You must use API names of data sources, objects, fields, and field values in Export ZOQL queries. API names do not necessarily match the corresponding names displayed in the Zuora user interface. For example, you must use "InvoiceItem" instead of "Invoice Item" or "Rechnungsposten" (German): ``` select BillToContact.FirstName from InvoiceItem ``` In the example: * `InvoiceItem` is the API name of the Invoice Item data source. * `BillToContact` is the API name of a Contact object that is related to an Invoice Item object. * `FirstName` is the API name of the First Name field in the Contact object. `InvoiceItem` is also called the "base" object of the Invoice Item data source. `BillToContact` is called a "joined" object. To determine API names: * For data sources and objects, refer to the listing in the Data Sources and Objects section, below. * For fields and field values, use the [Describe object](https://developer.zuora.com/v1-api-reference/api/operation/GET_Describe/) API operation. Changes to the "Describe object" API operation were introduced in version 85 of the Zuora WSDL. Prior to version 79 of the Zuora WSDL, some fields in data sources had different values from the corresponding fields in SOAP API objects. ## Limitations A maximum of 20,000 characters is allowed in an Export ZOQL query. The maximum export file size is 2047MB. If you have large data requests that go over this limit, you will get the following 403 HTTP response code from Zuora: `2047MB` Submit a request at [Zuora Global Support](http://support.zuora.com/) if you require additional assistance. We can work with you to determine if large file optimization is an option for you. > Learn how to use Zuora Export ZOQL to create data source exports through the Zuora API, offering powerful querying capabilities for related business objects. ## Docs - [Data Sources and Objects](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/data-sources-and-objects.md): A comprehensive list of objects available in each data source, highlighting dependencies on Zuora features and offering guidance on data source object availability. - [Export ZOQL Select Statements](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/export-zoql-select-statements.md): Learn how to use Export ZOQL for creating exports from Zuora data sources, including syntax differences, query examples, wildcard support, and handling reserved characters. - [Aggregate Functions](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/export-zoql-select-statements/aggregate-functions.md): Learn about the aggregate functions supported by Export ZOQL, including avg(), count(), max(), min(), and sum(), along with their limitations and examples. - [Export ZOQL Clauses](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/export-zoql-clauses.md): Learn about the ZOQL clauses such as order by, group by, having, and limit, which are used to sort, group, filter, and restrict query results. - [Export ZOQL Clause Limits](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/export-zoql-clauses/export-zoql-clause-limits.md): Overview of limits for Export ZOQL clauses, including restrictions on fields in group by clauses, alias function usage, and nested aggregate functions. - [Changes to the Describe API](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/changes-to-the-describe-api.md): The "Describe object" API call in Zuora WSDL 85 includes fields not available for data source exports, requiring integration checks for field availability. - [Field Values in Export ZOQL Data Sources](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/field-values-in-export-zoql-data-sources.md): Explains the differences in field values between data sources and the SOAP API in various versions of the Zuora WSDL, focusing on changes from version 78 to 79. - [Export ZOQL Filter Statements](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/export-zoql-filter-statements.md): Learn how to use Export ZOQL filter statements to create exports from Zuora data sources, including the use of logical operators and null values. - [Filter Statement reference](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/export-zoql-filter-statements/filter-statement-reference.md): This reference provides details on filter statements, including data types, supported operators, examples, and notes for boolean, dateTime, number, and string data types. - [Special date/time features in Export ZOQL](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/special-datetime-features-in-export-zoql.md): Explore special date and time features in Export ZOQL to simplify querying with timestamps, including relative date expressions and time zone specifications. - [Compare datetimes with dates](https://zuora.ferndocs.com/docs/platform/data/legacy-query-methods/export-zoql/special-datetime-features-in-export-zoql/compare-datetimes-with-dates.md): Learn how to filter objects in Export ZOQL by comparing datetime and date values, including handling time zones and ISO 8601 format.