Categories
Returns information about WordPress categories, including their names, descriptions, and post counts.
Table Specific Information
SELECT
The component uses the WordPress API to process some of the filters. The component processes other filters client-side within the component.
For example, the following queries are processed server side.
SELECT * FROM Categories WHERE Parent = 0
SELECT * FROM Categories ORDER BY Id
SELECT * FROM Categories WHERE Id IN ('130', '129')
Also, ordering by Count, Description and Name, is handled by the WordPress API.
Insert
To insert a category the following column is required: Name.
INSERT INTO Categories (Description, Name, Parent) VALUES ('This is an example Category', 'myCategory', '138')
Update
To update a category you must specify the following column: Id.
UPDATE Categories SET Name = 'updatedName', Description = 'Updated description.', Parent = 137 WHERE Id = '139'
Delete
To delete a category you must specify the following column: Id.
DELETE FROM Categories WHERE Id = '139'
Columns
| Name | Type | ReadOnly | References | Description |
| Id [KEY] | Integer | True |
A unique integer that identifies the category in WordPress and links posts, tags, and other taxonomy data associated with that category. | |
| Count | Integer | True |
The total number of posts currently assigned to the category, as returned by the WordPress API. | |
| Description | String | False |
The descriptive text defined in WordPress for the category, typically used to explain its purpose or the type of posts it contains. | |
| Link | String | True |
The full URL returned by WordPress that links to the public category page associated with this record. | |
| Name | String | False |
The category name defined in WordPress, representing the label shown on the site and used to organize related posts. | |
| Taxonomy | String | True |
The taxonomy type that classifies the category in WordPress. | |
| Parent | Integer | False |
The identifier of the parent category that this category belongs to. A value of 0 indicates that the category has no parent. |