Accounts
View many or all contacts by including their ID's or various filters.
Table Specific Information
Select
The driver uses the ActiveCampaign API to process some of the filters.
For example, the following queries are processed server side:
SELECT * FROM Accounts WHERE Id = 10003 SELECT * FROM Accounts WHERE Name = 'testAccount'
As a note, due to server-side performance issues, even when the property IncludeCustomFields is set to TRUE, the custom fields will appear only in the table schema with null values. To retrieve the values of the custom fields, please refer to the AccountCustomFieldData table.
Insert
Inserting an account requires specifying the account name.
INSERT INTO Accounts (Name) VALUES ('testAccount2') INSERT INTO Accounts (Name,AccountUrl) VALUES ('account','http://accountUrl.com/')
Additionally, the driver supports inserting account and account custom fields data from the Accounts table. All custom field columns start with CF_.
INSERT INTO Accounts (Name,CF_Description,CF_Hidden,CF_Number) VALUES ('testAccount3','custom field value','custom field value',123)
Update
The driver supports updating account information.
Additionally, it is possible to update account custom fields data from the Accounts table.
UPDATE Accounts SET Name = 'updatedName',AccountUrl = 'http://updatedAccountUrl.com/' WHERE Id = 1 UPDATE Accounts SET Name = 'updatedName',CF_Description = 'custom field value', CF_Hidden = 'custom field value' WHERE Id = 1
Delete
Remove all accounts or an account by specifying the Id of the account.
DELETE FROM Accounts WHERE Id = 10003
Columns
Name | Type | ReadOnly | Description |
Id [KEY] | String | True |
The Id column of the Accounts table. |
AccountUrl | String | False |
Account's website. |
ContactCount | Integer | True |
The ContactCount column of the Accounts table. |
CreatedTimestamp | Datetime | True |
The CreatedTimestamp column of the Accounts table. |
DealCount | Integer | True |
The DealCount column of the Accounts table. |
AccountContactsLink | String | True |
The AccountContactsLink column of the Accounts table. |
AccountCustomFieldDataLink | String | True |
The AccountCustomFieldDataLink column of the Accounts table. |
ContactEmailsLink | String | True |
The ContactEmailsLink column of the Accounts table. |
EmailActivitiesLink | String | True |
The EmailActivitiesLink column of the Accounts table. |
NotesLink | String | True |
The NotesLink column of the Accounts table. |
Name | String | False |
Account's name. |
UpdatedTimestamp | Datetime | True |
The UpdatedTimestamp column of the Accounts table. |