Endpoint Read Data (Query Mode - Max 200 Rows Only)
Name
get_module_data_coql
Description
Parameters
| Parameter | Required | Options |
|---|---|---|
|
Name:
Label: sql_query Your SQL query for CRM (i.e. COQL (CRM Object Query Language)). Limtation - You can fetch maximum 200 rows using COQL Query. To read all rows use Table mode. (refer to help link to learn more about COQL) |
Output Columns
| Label | Data Type (SSIS) | Data Type (SQL) | Length | Description | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| There are no Static columns defined for this endpoint. This endpoint detects columns dynamically at runtime. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Input Columns
| Label | Data Type (SSIS) | Data Type (SQL) | Length | Description | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| There are no Static columns defined for this endpoint. This endpoint detects columns dynamically at runtime. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Examples
SSIS
Use Zoho CRM Connector in API Source or in API Destination SSIS Data Flow components to read or write data.
API Source
| Optional Parameters | |
|---|---|
| sql_query | select Last_Name, First_Name, Full_Name from Contacts where Last_Name not like 'Boyle' limit 200 |
API Destination
| Optional Parameters | |
|---|---|
| sql_query | select Last_Name, First_Name, Full_Name from Contacts where Last_Name not like 'Boyle' limit 200 |
ODBC application
Use these SQL queries in your ODBC application data source:
Read data using COQL (Native SQL)
<p>Executes a COQL (CRM Object Query Language) query to retrieve data. This example demonstrates using the <code>get_module_data_coql</code> endpoint to run a server-side query, which can be more efficient than client-side filtering. Note that COQL queries have a limit of 200 rows.</p>
SELECT * from get_module_data_coql WITH(sql_query= 'select Last_Name, First_Name, Company from Leads where Company like ''Test'' limit 200')
SQL Server
Use these SQL queries in SQL Server after you create a data source in Data Gateway:
Read data using COQL (Native SQL)
<p>Executes a COQL (CRM Object Query Language) query to retrieve data. This example demonstrates using the <code>get_module_data_coql</code> endpoint to run a server-side query, which can be more efficient than client-side filtering. Note that COQL queries have a limit of 200 rows.</p>
DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * from get_module_data_coql WITH(sql_query= ''select Last_Name, First_Name, Company from Leads where Company like ''''Test'''' limit 200'')';
EXEC (@MyQuery) AT [LS_TO_ZOHO_CRM_IN_GATEWAY];