PostComments
Retrieves, creates, updates, and deletes comments on community posts.
Table-Specific Information
Select
The provider uses the Zendesk API to process WHERE clause conditions built with the following columns and operators:- Id supports the = operator.
- AuthorId supports the = operator.
- PostId supports the = operator.
For example, the following queries are processed server-side while other filters are processed client-side within the provider.
SELECT * FROM PostComments WHERE PostId = '31500138388637'
SELECT * FROM PostComments WHERE PostId = '16495383075612' AND Id = '16495529678108'
Insert
The following columns are required to insert: PostId and Body.INSERT INTO PostComments (PostId, Body) VALUES ('16495383075612', 'Comment Body')
You can also optionally include the Official column:
INSERT INTO PostComments (PostId, Body, Official) VALUES ('16495383075612', 'Comment Body', 'true')
Update
The following is an example of how to update the PostComments table:UPDATE PostComments SET Body = 'Updated Comment' WHERE PostId = '16495383075612' AND Id = '16495529678108'
Delete
You must specify the PostId and the Id of the comment to delete it.DELETE FROM PostComments WHERE PostId = '20414731778332' AND Id = '20414776629660'
Columns
| Name | Type | ReadOnly | References | Description |
| Id [KEY] | Long | True |
The unique Id automatically assigned when the comment is created. | |
| Url | String | True |
The API url of the comment. | |
| HtmlUrl | String | True |
The community url of the comment. | |
| Body | String | False |
The comment made by the author. | |
| AuthorId | Long | False |
The Id of the author of the comment. Writable on create by Help Center managers. | |
| PostId | Long | True |
Posts.Id |
The Id of the post on which the comment was made. |
| Official | Boolean | False |
Indicates whether the comment is marked as official. | |
| VoteSum | Integer | True |
The sum of upvotes (+1) and downvotes (-1), which may be positive or negative. | |
| VoteCount | Integer | True |
The total number of upvotes and downvotes. | |
| CreatedAt | Datetime | True |
The date and time when the comment was created. | |
| UpdatedAt | Datetime | True |
The date and time when the comment was last updated. |