Retrieve Data from a Data Extension

Use the SOAP API to retrieve information from a data extension in order to better target email sends or construct new groups of subscribers. You can retrieve up to 2500 records per request.

For calls that occur less often than once per hour, you can achieve better performance and efficiency using a data extract activity to deliver the data to your Enhanced FTP location. You can also implement this method if you notice drastically degraded performance as the number of rows in your call increases.

Use the sample code as an example to construct your own API calls. The sample code below retrieves data from a data extension named Airlines. In this example, the code pulls data from all columns in the data extension and filters the rows where IATA-Code is greater than or equal to 7. The code also continues to retrieve batches of data until all data has been retrieved.

The DataExtensionObject does not support LIKE operators in filters for the retrieve method.

Sample .NET Code

If you want to use the customer key (in this example, AirlinesKey) to identify the data extension instead of the data extension's name (in this example, Airlines), change the two lines from:


Sample .NET Code - Retrieving a Subscriber from a Data Extension

Sample Java Code (Axis 1.4)

Sample PHP Code

Sample SOAP Envelope

Example SOAP Response Envelope