Field 'params' doesn't have a default value

Phoca Guestbook - creating guestbooks in Joomla! CMS
guycarlens
Phoca Member
Phoca Member
Posts: 20
Joined: 12 Jul 2016, 18:54

Field 'params' doesn't have a default value

Post by guycarlens »

Hello

When i place a message in the backend of my guestbook https://zwemtechniek.coach/referenties the following error appears: https://zwemtechniek.coach/referenties

When i place a message in the frontend i receive an internal server 500 message.

I have the latest version of Phoca guestbook and Joomla 4.

Thanks

Guy

Tags:
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48386
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Field 'params' doesn't have a default value

Post by Jan »

Hi,

500 error - enable debug mode to see full error message (including file and line where this error occurrs)

Where exactly do you get this problem: Field 'params' doesn't have a default value

This seems like the params column in database has obsolete format :idea:

Jan
If you find Phoca extensions useful, please support the project
guycarlens
Phoca Member
Phoca Member
Posts: 20
Joined: 12 Jul 2016, 18:54

Re: Field 'params' doesn't have a default value

Post by guycarlens »

Hello Jan

Can you please have a look? Can i send you my login?

Thanks in advance.

Guy
guycarlens
Phoca Member
Phoca Member
Posts: 20
Joined: 12 Jul 2016, 18:54

Re: Field 'params' doesn't have a default value

Post by guycarlens »

Code: Select all

ExecutionFailureException  ExecutionFailureException  ParseError
HTTP 500 Whoops, looks like something went wrong.
Unclosed '{' on line 72
Exceptions 3Stack Traces 3
ParseError
Joomla\Database\Exception\
ExecutionFailureException
Table 'zwemtechniek_j4.gdstsj4_phocaguestbook_logging' doesn't exist

Joomla\Database\Exception\
ExecutionFailureException
Table 'zwemtechniek_j4.gdstsj4_phocaguestbook_logging' doesn't exist

in /home/inyzz1scfadz/public_html/libraries/vendor/joomla/database/src/Mysqli/MysqliStatement.php (line 437)
in /home/inyzz1scfadz/public_html/libraries/vendor/joomla/database/src/DatabaseDriver.php -> execute (line 675)
in /home/inyzz1scfadz/public_html/libraries/vendor/joomla/database/src/DatabaseDriver.php -> execute (line 1375)
in /home/inyzz1scfadz/public_html/libraries/vendor/joomla/database/src/Mysqli/MysqliDriver.php -> loadObjectList (line 625)
MysqliDriver->getTableColumns()
in /home/inyzz1scfadz/public_html/libraries/src/Table/Table.php (line 248)
        $key = $this->_db->getServerType() . ':' . $this->_db->getName() . ':' . $this->_tbl;        if (!isset(self::$tableFields[$key]) || $reload) {            // Lookup the fields for this table only once.            $name   = $this->_tbl;            $fields = $this->_db->getTableColumns($name, false);            if (empty($fields)) {                throw new \UnexpectedValueException(sprintf('No columns found for %s table', $name));            }
Table->getFields()
in /home/inyzz1scfadz/public_html/libraries/src/Table/Table.php (line 193)
Table->__construct()
in /home/inyzz1scfadz/public_html/administrator/components/com_phocaguestbook/tables/phocaguestbooklogging.php (line 24)
TablePhocaguestbookLogging->__construct()
in /home/inyzz1scfadz/public_html/libraries/src/Table/Table.php (line 317)
Table::getInstance()
in /home/inyzz1scfadz/public_html/libraries/src/MVC/Factory/LegacyFactory.php (line 132)
LegacyFactory->createTable()
in /home/inyzz1scfadz/public_html/libraries/src/MVC/Model/BaseDatabaseModel.php (line 235)
BaseDatabaseModel->_createTable()
in /home/inyzz1scfadz/public_html/libraries/src/MVC/Model/BaseDatabaseModel.php (line 267)
BaseDatabaseModel->getTable()
in /home/inyzz1scfadz/public_html/components/com_phocaguestbook/controllers/phocaguestbook.php (line 68)
PhocaguestbookControllerPhocaguestbook->submit()
in /home/inyzz1scfadz/public_html/libraries/src/MVC/Controller/BaseController.php (line 678)
BaseController->execute()
in /home/inyzz1scfadz/public_html/components/com_phocaguestbook/phocaguestbook.php (line 20)
require_once('/home/inyzz1scfadz/public_html/components/com_phocaguestbook/phocaguestbook.php')
in /home/inyzz1scfadz/public_html/libraries/src/Dispatcher/LegacyComponentDispatcher.php (line 71)
LegacyComponentDispatcher::Joomla\CMS\Dispatcher\{closure}()
in /home/inyzz1scfadz/public_html/libraries/src/Dispatcher/LegacyComponentDispatcher.php (line 73)
LegacyComponentDispatcher->dispatch()
in /home/inyzz1scfadz/public_html/libraries/src/Component/ComponentHelper.php (line 361)
ComponentHelper::renderComponent()
in /home/inyzz1scfadz/public_html/libraries/src/Application/SiteApplication.php (line 208)
SiteApplication->dispatch()
in /home/inyzz1scfadz/public_html/libraries/src/Application/SiteApplication.php (line 249)
SiteApplication->doExecute()
in /home/inyzz1scfadz/public_html/libraries/src/Application/CMSApplication.php (line 293)
CMSApplication->execute()
in /home/inyzz1scfadz/public_html/includes/app.php (line 61)
require_once('/home/inyzz1scfadz/public_html/includes/app.php')
in /home/inyzz1scfadz/public_html/index.php (line 32)
guycarlens
Phoca Member
Phoca Member
Posts: 20
Joined: 12 Jul 2016, 18:54

Re: Field 'params' doesn't have a default value

Post by guycarlens »

This is the error when i place a message myself.
Can anyone help me out?
Can i give my login?
User avatar
Benno
Phoca Hero
Phoca Hero
Posts: 9435
Joined: 04 Dec 2008, 11:58
Location: Germany
Contact:

Re: Field 'params' doesn't have a default value

Post by Benno »

Hi,
Table 'zwemtechniek_j4.gdstsj4_phocaguestbook_logging' doesn't exist
Check with phpMyAdmin if the table #__phocaguestbook_logging exists in your database or not.
If not you can create it manualy.
Backup your database first, replace #_ with your database prefix and run this query:

Code: Select all

CREATE TABLE IF NOT EXISTS `#__phocaguestbook_logging` (
  `id` int(11) unsigned NOT NULL auto_increment,
  `catid` int(11) NOT NULL default '0',
  `postid` int(11) NOT NULL default '0',
  `captchaid` smallint(6) NOT NULL default '0',
  `fields` tinyint(4) NOT NULL default '0',
  `hidden_field` tinyint(4) NOT NULL default '0',
  `forbidden_word` tinyint(4) NOT NULL default '0',
  `used_time` int(11) NOT NULL default '0',
  `session` tinyint(4) NOT NULL default '0',
  `incoming_page` varchar(255) NOT NULL default '',
  `ip` varchar(50) NOT NULL default '',
  `ip_list` tinyint(4) NOT NULL default '0',
  `ip_stopforum` tinyint(4) NOT NULL default '0',
  `ip_stopforum_txt` varchar(128) NOT NULL default '',
  `ip_honeypot` tinyint(4) NOT NULL default '0',
  `ip_botscout` tinyint(4) NOT NULL default '0',
  `ip_botscout_txt` varchar(128) NOT NULL default '',
  `content_akismet` tinyint(4) NOT NULL default '0',
  `content_akismet_txt` varchar(128) NOT NULL default '',
  `content_mollom` tinyint(4) NOT NULL default '0',
  `content_mollom_txt` varchar(128) NOT NULL default '',
  `date` datetime NOT NULL,
  `state` tinyint(3) NOT NULL default '0',
  `params` text,
  PRIMARY KEY  (`id`),
  KEY `state` (`state`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 DEFAULT COLLATE=utf8mb4_unicode_ci;

Kind regards,
Benno
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48386
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Field 'params' doesn't have a default value

Post by Jan »

Should be OK now, the params column didn't have default value "NULL" (this could be because it was created in old instance and not installed by new version).

Jan
If you find Phoca extensions useful, please support the project
laloly
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 31 Aug 2023, 18:08

Re: Field 'params' doesn't have a default value

Post by laloly »

Hello,

Still the same error after doing everything indicated
Joomla 4.3.4 and Phoca Guestbook 4.0.3.

When I am in backend, it's impossible for me to register a new comment, I have the error = Field 'params' doesn't have a default value.

When I am in Frontend as an administrator or registered customer, nothing happens, the comment isn't recorded either...

I did what is specified in a previous post by Benno (Check with phpMyAdmin if the table #__phocaguestbook_logging exists in your database or not. If not you can create it manually) but, it's still wrong.
I reinstalled the component but it's still buggy...

Can anybody help me ?
Many thanks.
Laloly
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48386
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Field 'params' doesn't have a default value

Post by Jan »

Hi,

Field 'params' doesn't have a default value

In your database, e.g. via phpMyAdmin, you can fix the "params" column in case it has wrong type, for example:

Code: Select all

ALTER TABLE `#__phocaguestbook_logging` CHANGE `params` `params` text;
- change #__ to your prefix
- be sure the error message "Field "params" ... " is really coming from this table (if another table, just change the table in SQL query)

See the similar situation in other extension:
viewtopic.php?p=176384#p176384

Jan
If you find Phoca extensions useful, please support the project
laloly
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 31 Aug 2023, 18:08

Re: Field 'params' doesn't have a default value

Post by laloly »

Sorry for the late response, I was on vacation. Thank you for your message, I had already found this solution but it doesn't change anything.

Valerie
Post Reply