wp_clientoctopus_invoices
StaticStores clientoctopus invoices data created by this plugin.
Column Definitions
| Column | Type | Nullable |
|---|---|---|
| 🔑id | BIGINT UNSIGNED | NO |
| owner_id | BIGINT UNSIGNED | NO |
| client_id | BIGINT UNSIGNED | YES |
| invoice_number | INT UNSIGNED | NO |
| token | VARCHAR(64) | NO |
| status | ENUM('draft','sent','paid','overdue','cancelled') | NO |
| title | VARCHAR(255) | NO |
| currency | VARCHAR(3) | NO |
| line_items | LONGTEXT | YES |
| discount_type | ENUM('percentage','fixed') | NO |
| discount_value | DECIMAL(10,2) | NO |
| vat_pct | DECIMAL(5,2) | NO |
| vat_number | VARCHAR(50) | YES |
| notes | TEXT | YES |
| due_date | DATE | YES |
| issue_date | DATE | NO |
| payment_terms | VARCHAR(100) | YES |
| po_number | VARCHAR(100) | YES |
| total_amount | DECIMAL(12,2) | NO |
| stripe_session_id | VARCHAR(255) | YES |
| stripe_payment_intent_id | VARCHAR(255) | YES |
| sent_at | DATETIME | YES |
| paid_at | DATETIME | YES |
| created_at | DATETIME | YES |
| updated_at | DATETIME | YES |
| deleted_at | DATETIME | YES |
CREATE TABLE Statement
CREATE TABLE wp_clientoctopus_invoices ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, owner_id BIGINT UNSIGNED NOT NULL, client_id BIGINT UNSIGNED DEFAULT NULL, invoice_number INT UNSIGNED NOT NULL DEFAULT 0, token VARCHAR(64) NOT NULL DEFAULT '', status ENUM('draft','sent','paid','overdue','cancelled') NOT NULL DEFAULT 'draft', title VARCHAR(255) NOT NULL DEFAULT '', currency VARCHAR(3) NOT NULL DEFAULT 'GBP', line_items LONGTEXT DEFAULT NULL, discount_type ENUM('percentage','fixed') NOT NULL DEFAULT 'percentage', discount_value DECIMAL(10,2) NOT NULL DEFAULT 0, vat_pct DECIMAL(5,2) NOT NULL DEFAULT 0, vat_number VARCHAR(50) DEFAULT NULL, notes TEXT DEFAULT NULL, due_date DATE DEFAULT NULL, issue_date DATE NOT NULL, payment_terms VARCHAR(100) DEFAULT NULL, po_number VARCHAR(100) DEFAULT NULL, total_amount DECIMAL(12,2) NOT NULL DEFAULT 0, stripe_session_id VARCHAR(255) DEFAULT NULL, stripe_payment_intent_id VARCHAR(255) DEFAULT NULL, sent_at DATETIME DEFAULT NULL, paid_at DATETIME DEFAULT NULL, created_at DATETIME DEFAULT NULL, updated_at DATETIME DEFAULT NULL, deleted_at DATETIME DEFAULT NULL, PRIMARY KEY (id), UNIQUE KEY token (token), KEY owner_id (owner_id), KEY client_id (client_id), KEY status (status), KEY owner_status (owner_id, status, deleted_at) ) $charset_collate;" );Safe to delete?
If you have uninstalled Client Octopus, this table is generally safe to remove. However, always back up your database first.
Note: Some plugins share tables or are dependencies of other plugins. Verify nothing else depends on this table before dropping it.
How to remove this table
DROP TABLE IF EXISTS `wp_clientoctopus_invoices`;
Run this query using phpMyAdmin, Adminer, or your MySQL client. Back up first.
Other tables from Client Octopus