ListSegments
A list of available segments.
Table Specific Information
SELECT, INSERT, UPDATE, and DELETE are supported for ListSegments.
Select
The server will use the Mailchimp API to process WHERE clause conditions built with the following column and operator. The rest of the filter is executed client-side within the server.
- Id supports the '=' operator.
- Type supports the '=' operator.
- ListId supports the '=' operator.
- IncludeCleaned supports the '=' operator.
- IncludeUnsubscribed supports the '=' operator.
- IncludeTransactional supports the '=' operator.
- CreatedAt supports the '=,<,>,<=,>=' operator.
- UpdatedAt supports the '=,<,>,<=,>=' operator.
SELECT * FROM ListSegments WHERE ListId = '5152' and Id = '4458' SELECT * FROM ListSegments WHERE Type = 'saved' SELECT * FROM ListSegments WHERE IncludeCleaned = true SELECT * FROM ListSegments WHERE IncludeTransactional = true SELECT * FROM ListSegments WHERE IncludeUnsubscribed = true SELECT * FROM ListSegments WHERE UpdatedAt = '2024-02-07 00:00:37.0' SELECT * FROM ListSegments WHERE UpdatedAt >= '2024-02-07 00:00:37.0' SELECT * FROM ListSegments WHERE UpdatedAt <= '2024-02-07 00:00:37.0' SELECT * FROM ListSegments WHERE UpdatedAt > '2024-02-07 00:00:37.0' SELECT * FROM ListSegments WHERE UpdatedAt < '2024-02-07 00:00:37.0'
Insert
The Name and ListID are required for INSERTs.
INSERT INTO ListSegments (Name, ListID) VALUES ('myNewListSegment', 'myListID')
Columns
| Name | Type | ReadOnly | Description |
| Id [KEY] | String | True |
An integer to uniquely identify the segment. |
| Name | String | False |
The name of the segment. |
| MemberCount | Integer | True |
The number of active subscribers currently included in the segment. |
| Type | String | True |
The type of segment: saved, static, or fuzzy. |
| CreatedAt | Datetime | True |
The time and date the segment was created. |
| UpdatedAt | Datetime | True |
The time and date the segment was last updated. |
| Options_Match | String | False |
Match type of 'any' or 'all'. |
| Options_Conditions | String | False |
An array of segment conditions. |
| ListId [KEY] | String | False |
The id for the list. |
Pseudo-Columns
Pseudo column fields are used in the WHERE clause of SELECT statements and offer a more granular control over the tuples that are returned from the data source.
| Name | Type | Description |
| EmailList | String |
A comma-separated list of emails that you want to include in this ListSegment. |
| IncludeCleaned | Boolean |
Include cleaned members in response, only valid for SELECT |
| IncludeTransactional | Boolean |
Include transactional members in response, only valid for SELECT |
| IncludeUnsubscribed | Boolean |
Include unsubscribed members in response, only valid for SELECT |