MG 1.1 Can't Install 1.1.6a

Steve F

Well-known member
This might be related to xampp on my localhost but not certain. I get the below when trying to install on XF 1.5.7

Code:
Server Error

Mysqli prepare error: Table 'dev.xengallery_field' doesn't exist

Zend_Db_Statement_Mysqli->_prepare() in C:\xampp\htdocs\dev\library\Zend\Db\Statement.php at line 115
Zend_Db_Statement->__construct() in C:\xampp\htdocs\dev\library\Zend\Db\Adapter\Mysqli.php at line 381
Zend_Db_Adapter_Mysqli->prepare() in C:\xampp\htdocs\dev\library\Zend\Db\Adapter\Abstract.php at line 478
Zend_Db_Adapter_Abstract->query() in C:\xampp\htdocs\dev\library\Zend\Db\Adapter\Abstract.php at line 734
Zend_Db_Adapter_Abstract->fetchAll() in C:\xampp\htdocs\dev\library\XenGallery\Model\Field.php at line 37
XenGallery_Model_Field->getGalleryFieldsInCategories() in C:\xampp\htdocs\dev\library\XenGallery\Model\Field.php at line 552
XenGallery_Model_Field->rebuildFieldCategoryAssociationCache() in C:\xampp\htdocs\dev\library\XenGallery\Install.php at line 62
XenGallery_Install::installer()
call_user_func() in C:\xampp\htdocs\dev\library\XenForo\Model\AddOn.php at line 215
XenForo_Model_AddOn->installAddOnXml() in C:\xampp\htdocs\dev\library\XenForo\Model\AddOn.php at line 169
XenForo_Model_AddOn->installAddOnXmlFromFile() in C:\xampp\htdocs\dev\library\XenForo\ControllerAdmin\AddOn.php at line 188
XenForo_ControllerAdmin_AddOn->actionInstall() in C:\xampp\htdocs\dev\library\XenForo\FrontController.php at line 351
XenForo_FrontController->dispatch() in C:\xampp\htdocs\dev\library\XenForo\FrontController.php at line 134
XenForo_FrontController->run() in C:\xampp\htdocs\dev\admin.php at line 13
 
I do not use the Media Galley myself, but having a look at the error message, it appears that xengallery_field table, does not exist. Can you try to add it manually with a query and see if that will help.
 
Hi Steve,

I semi-periodically do clean installs of XFMG, especially when changes are made to the installer. All seems to be ok right now and we've had no other reports of this.

A clean install worked fine, and the query in the code to create the xengallery_field table seems to be working fine.

Just to be clear, what have you done so far?
No joy, there were 3 but none were xengallery_field.
There were 3 what? There are three field related tables, but one of them is xengallery_field, and there are obviously considerable more than 3 tables in total. What were the 3 tables, specifically?

This appears to be the code triggering the error:

PHP:
// Rebuilds the field cache after the default Example Category has been inserted.
if (!self::$_version)
{
   XenForo_Model::create('XenGallery_Model_Field')->rebuildFieldCategoryAssociationCache(1);
}

This should be running after all of the install queries have completed, but if it only has 3 tables available at that time then something must be going wrong somewhere.
 
That's rather random.

The tables that have been created are not even in a sequential order.

At this point all I can say is that this is unexpected and cannot be reproduced. It is almost certainly server related. I appreciate this is a bit of a non-solution. However, from here I would recommend inspecting PHP and MySQL error logs to see if anything is being logged that may explain this.

I would also recommend deleting the version of 1.1.6a you have, and re-downloading it from scratch, even with a different browser if possible and uploading with a different FTP application. There's a possibility it could be a corrupted download or something but that would be presenting itself in a weird way (that kind of fault would normally be an all or nothing type thing).
 
I did try redownloading the package with the same result. I think you may have missed the part in the OP that this is XAMPP on my local machine.

I created a new fresh XF install and it installed fine, same package. I also did a fresh install on our webserver which also went fine. Seems isolated to this specific local install.
 
I didn't miss that. The advice still stands, really.

Something must be going wrong, and that something must be being suppressed, so I'm expecting that the PHP or MySQL error logs might contain some hints. It's been a while since I used XAMPP so I'm not sure if these logs need enabling or what their default locations are.
 
For what it's worth, I've been using XAMPP for years and have never had any issues installing or upgrading XF, official add-ons, or third party add-ons.
 
Alright - it's installing now.

In the 'C:\xampp\mysql\data\dev' (dev being the xf install) directory there were these files. If you notice the date being from last year it is these that caused the issue since I had copied XAMPP from my old HD to this SSD and still used 'dev' as the install. ;)

See I knew it was something simple/obvious lol. Thanks for the help guys.
upload_2016-4-22_21-40-58.webp
 
Back
Top Bottom