Error in address_country setting main attributes default value

  • Posts: 14
  • Thank you received: 0
  • Hikashop Essential
5 years 9 months ago #294709

-- HikaShop version -- : 3.4.1
-- Joomla version -- : 3.8.10
-- PHP version -- : 7.1.0
-- Browser(s) name and version -- : Safari 11.1.1
-- Error-message(debug-mod must be tuned on) -- : An error has occurred.
1054 Unknown column 'guest_mode' in 'field list'
/xxxxxxx/xxxxxx/xxxxx/xxxxxxxx/libraries/joomla/database/driver/mysqli.php:650
Call stack
# Function Location
1 () JROOT/libraries/joomla/database/driver/mysqli.php:650
2 JDatabaseDriverMysqli->execute() JROOT/libraries/joomla/database/driver.php:2278
3 JDatabaseDriver->updateObject() JROOT/administrator/components/com_hikashop/helpers/helper.php:1940
4 hikashopClass->save() JROOT/administrator/components/com_hikashop/classes/field.php:1561
5 hikashopFieldClass->save() JROOT/administrator/components/com_hikashop/classes/field.php:609
6 hikashopFieldClass->handleZone() JROOT/administrator/components/com_hikashop/classes/field.php:562
7 hikashopFieldClass->prepareFields() JROOT/administrator/components/com_hikashop/classes/field.php:158
8 hikashopFieldClass->getFields() JROOT/administrator/components/com_hikashop/views/field/view.html.php:34
9 FieldViewField->form() JROOT/administrator/components/com_hikashop/views/field/view.html.php:19
10 FieldViewField->display() JROOT/libraries/src/MVC/Controller/BaseController.php:672
11 Joomla\CMS\MVC\Controller\BaseController->display() JROOT/administrator/components/com_hikashop/helpers/helper.php:1880
12 hikashopController->display() JROOT/administrator/components/com_hikashop/helpers/helper.php:1658
13 hikashopController->edit() JROOT/libraries/src/MVC/Controller/BaseController.php:710
14 Joomla\CMS\MVC\Controller\BaseController->execute() JROOT/administrator/components/com_hikashop/helpers/helper.php:1858
15 hikashopController->execute() JROOT/administrator/components/com_hikashop/hikashop.php:71
16 require_once() JROOT/libraries/src/Component/ComponentHelper.php:382
17 Joomla\CMS\Component\ComponentHelper::executeComponent() JROOT/libraries/src/Component/ComponentHelper.php:357
18 Joomla\CMS\Component\ComponentHelper::renderComponent() JROOT/libraries/src/Application/AdministratorApplication.php:101
19 Joomla\CMS\Application\AdministratorApplication->dispatch() JROOT/libraries/src/Application/AdministratorApplication.php:159
20 Joomla\CMS\Application\AdministratorApplication->doExecute() JROOT/libraries/src/Application/CMSApplication.php:195
21 Joomla\CMS\Application\CMSApplication->execute() JROOT/administrator/index.php:51

Ok. I seemed to have uncovered an error, and not sure how to fix it.

I went to Display > Custom fields. Clicked on address_country. In extra attributes, I changed "Add a 'Please select' value" to "Yes". Then in Main Attributes, I changed Default Value to "Please make a selection from the list". Then I clicked "Save". Immediately, after I clicked save, I get "An error has occurred. 1054 Unknown column 'guest_mode' in 'field list'". And now I can't get to change it back. I goes directly to this error every time I click on address_country. Can you help me fix this?

Michael

Last edit: 5 years 9 months ago by michaelgilkes.

Please Log in or Create an account to join the conversation.

  • Posts: 4502
  • Thank you received: 610
  • MODERATOR
5 years 9 months ago #294757

Hello,

First things to do is to make a check database :



Other point to precise, how can you change this default value in Main Attributes for "Please make a selection from the list" ?



Here, we have a dropdown to select selected only country value, and so I wonder how you can change this another value type ?...
Can you provide a screenshot ?

Awaiting news from you.
Regards

Last edit: 5 years 9 months ago by Philip.

Please Log in or Create an account to join the conversation.

  • Posts: 14
  • Thank you received: 0
  • Hikashop Essential
5 years 9 months ago #294771

Hi Philip,

Please check my explanation. you have to change "Add a 'Please select' value" to "Yes" in extra attributes, first. See my screenshot.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 12953
  • Thank you received: 1778
5 years 9 months ago #294773

Hello,

I tried to reproduce your issue on my end and it worked fine, did you tried to use the "Check database" option via "Hikashop->System->Configuration" ?

Best regards,
Mohamed Thelji.

Please Log in or Create an account to join the conversation.

  • Posts: 14
  • Thank you received: 0
  • Hikashop Essential
5 years 9 months ago #294790

Hi Mohamed,

I don't understand why you are not able to reproduce this error given my explanation of the steps I took. However, I just did the same steps again and the error came up. The check database didn't fix the issue either. To fix it I had to manually go to the mysql database backend, go the hikashop_field table, edit the row with field_namekey address_country and using the value from a backup copy of my database, add the value in the backup for field_default column, since I found it blank.

I made a screen video of it happening, but your file attachment won't allow me to upload it even though I zipped it up and it was under 4mb. I hope you can reproduce it.

Here are my steps again for your reference:

1. I went to Display > Custom fields. Clicked on address_country.
2. In extra attributes, I changed "Add a 'Please select' value" to "Yes".
3. Then in Main Attributes, I changed Default Value to "Please make a selection from the list".
4. Then I clicked "Save". Immediately, after I clicked save, I get "An error has occurred. 1054 Unknown column 'guest_mode' in 'field list'".

You must do step 2 in order to reproduce the error. In the screenshot provided by Philip, "Add a 'Please select' value" in extra attributes was set to "No". If it is set to no, then you can't do step 3. Set it to "Yes", and then you should be able to reproduce the error. I provided another screenshot. you can see the option appear right at the top above Afghanistan.

Thanks,
Michael

Attachments:
Last edit: 5 years 9 months ago by michaelgilkes. Reason: adding screenshot

Please Log in or Create an account to join the conversation.

  • Posts: 81484
  • Thank you received: 13062
  • MODERATOR
5 years 9 months ago #294811

Hi,

Thank you for the details. We've added a patch for that.
Please download the install package on our website and install it again and that should help.

Please Log in or Create an account to join the conversation.

Time to create page: 0.083 seconds
Powered by Kunena Forum