Page 1 of 1
500 Table '_phocacart_content_types' doesn't exist
Posted: 04 Mar 2024, 16:18
by adm
PhocaCart 5.0.0Beta36
During the update, the table _phocacart_content_types was not created. The error occurs, when you click on categories in the backend.
Re: 500 Table '_phocacart_content_types' doesn't exist
Posted: 04 Mar 2024, 16:41
by Benno
Hi,
unzip
com_phocacart_v5.0.0Beta36.zip local on your pc. Then go to:
admin-->update-->sql-->mysql-->5.0.0.sql
There you find all 5.0.0 querys.
To create 'phocacart_content_types' table run this queries in phpMyAdmin:
Code: Select all
CREATE TABLE IF NOT EXISTS `#__phocacart_content_types` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`title` varchar(255) NOT NULL,
`context` varchar(255) NOT NULL,
`published` tinyint(1) NOT NULL DEFAULT 0,
`checked_out` int(11),
`checked_out_time` datetime,
`ordering` int(11) NOT NULL DEFAULT 0,
`params` text,
PRIMARY KEY (`id`),
KEY `idx_context` (`context`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 DEFAULT COLLATE=utf8mb4_unicode_ci;
INSERT INTO `#__phocacart_content_types` (`id`, `title`, `context`, `published`, `ordering`, `params`)
VALUES (1, 'COM_PHOCACART_CONTENT_TYPE_CATEGORY_DEFAULT', 'category', 1, 1, '{}');
INSERT INTO `#__phocacart_content_types` (`id`, `title`, `context`, `published`, `ordering`, `params`)
VALUES (2, 'COM_PHOCACART_CONTENT_TYPE_RELATED_DEFAULT', 'product_related', 1, 1, '{}');
Change:
#_
to your database prefix before.
Kind regards,
Benno
Re: 500 Table '_phocacart_content_types' doesn't exist
Posted: 04 Mar 2024, 16:49
by adm
Now missing field `category_type`. Addes with:
ALTER TABLE `#__phocacart_categories` ADD COLUMN `category_type` INT(11) AFTER `owner_id`;
Now there is no error, but no category will be displayed.
Re: 500 Table '_phocacart_content_types' doesn't exist
Posted: 04 Mar 2024, 17:07
by adm
Fix it with:
UPDATE _phocacart_categories SET category_type = 1
Re: 500 Table '_phocacart_content_types' doesn't exist
Posted: 04 Mar 2024, 17:19
by Benno
Ok.
Kind regards,
Benno