Forum
Perch standard with shop - countries missing
Hi,
Am experimenting with Perch Shop using standard Perch. I'm working through the initial setup (no front end pages yet; just playing with admin), but the countries list is empty, probably largely because the countries database table (perch2_shop_countries) is empty. Is this a limitation of using standard Perch, or have I missed something, or ... ?
Thanks for your help :)
Diagnostics:
Perch: 2.8.29, PHP: 5.4.45, MySQL: mysqlnd 5.0.10 - 20111026 - $Id: c85105d7c6f7d70d609bb4c000257868a40840ab $, with PDO
Server OS: Linux, apache2handler
Installed apps: content (2.8.29), assets (2.8.29), categories (2.8.29), perch_shop_orders (1.0.2), perch_shop_products (1.0.2), perch_shop (1.0.2), perch_members (1.5)
App runtimes: <?php $apps_list = array( 'content', 'categories', 'perch_members', 'perch_shop', );
PERCH_LOGINPATH: /perch
PERCH_PATH: /home/n2bspub/public_html/perch
PERCH_CORE: /home/n2bspub/public_html/perch/core
PERCH_RESFILEPATH: /home/n2bspub/public_html/perch/resources
Image manipulation: GD
PHP limits: Max upload 6M, Max POST 8M, Memory: 96M, Total max file upload: 6M
F1: 2edba60ed1f613d6dd804feb202456a2
Resource folder writeable: Yes
HTTP_HOST: <hidden by me>
DOCUMENT_ROOT: /home/n2bspub/public_html
REQUEST_URI: /perch/core/settings/diagnostics/
SCRIPT_NAME: /perch/core/settings/diagnostics/index.php
Update: Located the database insert in setup. The number of columns in the table doesn't match the number of fields defined in INSERT INTO. I'm guessing the last column shouldn't be there, as PerchShop_Countries.class.php contains the same fields as INSERT INTO. Is it 'safe' to remove this last column, or did something not get updated somewhere which it will need later?
Which column are you talking about?
Hi,
Apologies for not being clearer! In data.sql in the perch_shop app:
Six fields in INSERT statement, seven fields in the data. db.sql tells it to create seven fields:
so it throws it when it gets six for the data. PerchShop_Countries.class.php also looks for six fields:
My initial question was whether I can remove the last field (countryActive), but having just looked at db.sql, I'm thinking probably not! Is countryActive being used anywhere at the moment?
Thanks :)
countryActive
has a default value, so it doesn't need to be included in the insert.If I attempt to run the INSERT manually (via phpMyAdmin) I get the error "Column count doesn't match value count at row 1" because there are six columns and seven values. Never mind; I'll sort it out this end.