Problems after update from 2.8.18 to 2.9.1

In this board you can talk about general questions about phpMyFAQ

Moderator: Thorsten

Post Reply
MRi
Posts: 61
Joined: Mon Sep 22, 2014 12:52 pm

Problems after update from 2.8.18 to 2.9.1

Post by MRi »

I upgraded from 2.8.18 t9 2.9.1.

I used the documented way.
1. Problem was that I had to change the database.php type from mysql to Mysqli!
2. After this change I made the setup/update.php call, this succeded
3. After this I was able to access kb.grutzeck.de/admin
4. I switched to the default template
5. I used the default .htaccess file
6. Now I receive an white page when openeing our kb.
7. I added DEBUG true to the bootstrap.php
8. I received an error
Fatal error: Call to a member function fetch_object() on boolean in /homepages/36/d382738520/htdocs/kb.grutzeck.de/inc/PMF/DB/Mysqli.php on line 153
9. I changed the mysqli.php and added if (!is_object($result)) { echo debug_print_backtrace(); }

Now I get the error:
#0 PMF_DB_Mysqli->fetchObject() called at [/homepages/36/d382738520/htdocs/kb.grutzeck.de/inc/PMF/Faq.php:2101]
#1 PMF_Faq->getTopTenData(10, 0, de) called at [/homepages/36/d382738520/htdocs/kb.grutzeck.de/inc/PMF/Faq.php:1788]
#2 PMF_Faq->getTopTen(visits) called at [/homepages/36/d382738520/htdocs/kb.grutzeck.de/index.php:633]
Fatal error: Call to a member function fetch_object() on boolean in /homepages/36/d382738520/htdocs/kb.grutzeck.de/inc/PMF/DB/Mysqli.php on line 154

And now I don't know what to do further?
Seams that my DB-Access doesn't work

The current DB version is MySQL 5.1
MRi
Posts: 61
Joined: Mon Sep 22, 2014 12:52 pm

Re: Problems after update from 2.8.18 to 2.9.1

Post by MRi »

Just upgraded the DB from MySQL 5.1 to 5.5.
No change!
Thorsten
Posts: 15562
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: Problems after update from 2.8.18 to 2.9.1

Post by Thorsten »

Hi,

so, the admin section is working?

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
MRi
Posts: 61
Joined: Mon Sep 22, 2014 12:52 pm

Re: Problems after update from 2.8.18 to 2.9.1

Post by MRi »

Yes!
Thorsten
Posts: 15562
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: Problems after update from 2.8.18 to 2.9.1

Post by Thorsten »

Hi,

so, the DB connection is working. What language do you use?

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
MRi
Posts: 61
Joined: Mon Sep 22, 2014 12:52 pm

Re: Problems after update from 2.8.18 to 2.9.1

Post by MRi »

I use German.

Currently you can open the faq under kb-neu.grutzeck.de
I just implemented a new subdomain to keep the old one running as long as I have problems with 2.9.1
MRi
Posts: 61
Joined: Mon Sep 22, 2014 12:52 pm

Re: Problems after update from 2.8.18 to 2.9.1

Post by MRi »

I have also problems in the Admin mode.

Choosing Modify FAQs (FAQs Bearbeiten) I get:

#0 PMF_DB_Mysqli->fetchObject() called at [/homepages/36/d382738520/htdocs/kb2.9.1.grutzeck.de/inc/PMF/Faq.php:1515]
#1 PMF_Faq->getAllRecords(1, , ) called at [/homepages/36/d382738520/htdocs/kb2.9.1.grutzeck.de/admin/record.show.php:190]
#2 require(/homepages/36/d382738520/htdocs/kb2.9.1.grutzeck.de/admin/record.show.php) called at [/homepages/36/d382738520/htdocs/kb2.9.1.grutzeck.de/admin/index.php:267]
Fatal error: Call to a member function fetch_object() on boolean in /homepages/36/d382738520/htdocs/kb2.9.1.grutzeck.de/inc/PMF/DB/Mysqli.php on line 154
MRi
Posts: 61
Joined: Mon Sep 22, 2014 12:52 pm

Re: Problems after update from 2.8.18 to 2.9.1

Post by MRi »

Found the error

The problem was the change og the DB-Type from mysql to Mysqli!

Is used the same name as the filename in inc\PMF\DB\Mysqli.php and I used the same case
So Mysqli was in the database.php .

When the update.php was executed the switch case blocks are case sensitive. So a few SQL statements were not executed:
ALTER TABLE kb_faqdata CHANGE datum updated VARCHAR(15) NOT NULL;
ALTER TABLE kb_faqdata_revisions CHANGE datum updated VARCHAR(15) NOT NULL;
ALTER TABLE kb_faqdata ADD created TIMESTAMP DEFAULT CURRENT_TIMESTAMP;
ALTER TABLE kb_faqdata_revisions ADD created TIMESTAMP DEFAULT CURRENT_TIMESTAMP;


I just checked all changes step by step.

Maybe the allowed values in the database.php should be checked on their correct spelling and case.

So this is solved for now.
Thorsten
Posts: 15562
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: Problems after update from 2.8.18 to 2.9.1

Post by Thorsten »

Hi,

ah, good to know. I will add a check in 2.9.2 if someone tries to upgrade a "mysql" version.

Thanks!

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
Post Reply