Can't access Admin panel after 4-5 upgrade

Need help upgrading your Joomla! website or converting to Joomla! 5.x?

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Post Reply
BobShawAU
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Wed Sep 23, 2020 1:59 am

Can't access Admin panel after 4-5 upgrade

Post by BobShawAU » Mon Apr 15, 2024 10:09 am

Hi,
I upgraded Joomla 4 to 5.0.3. The website appears to work fine but I can't access the backend. After login I get the following:
mysqli_sql_exception mysqli_sql_exception
HTTP 500 Whoops, looks like something went wrong.
Unknown column 'a.ordering' in 'order clause'
mysqli_sql_exception
Show exception properties
mysqli_sql_exception {#2172 ▼
#sqlstate: "42S22"
}
in /usr/www/users/takemore/ai/libraries/vendor/joomla/database/src/Mysqli/MysqliStatement.php (line 138)
in /usr/www/users/takemore/ai/libraries/vendor/joomla/database/src/Mysqli/MysqliStatement.php -> prepare (line 138)
in /usr/www/users/takemore/ai/libraries/vendor/joomla/database/src/Mysqli/MysqliDriver.php -> __construct (line 1020)
in /usr/www/users/takemore/ai/libraries/vendor/joomla/database/src/DatabaseDriver.php -> prepareStatement (line 1785)
DatabaseDriver->setQuery()
in /usr/www/users/takemore/ai/administrator/components/com_menus/src/Helper/MenusHelper.php (line 816)
if ($iJoin) { $query->join('INNER', $iJoin); } $results = $db->setQuery($query)->loadObjectList(); // Skip the entire group if no items to iterate over. if ($results) { // Show the repeatable group heading node only if not set as hidden. if (!$hidden) {
MenusHelper::loadXml()
in /usr/www/users/takemore/ai/administrator/components/com_menus/src/Helper/MenusHelper.php (line 841)
MenusHelper::loadXml()
in /usr/www/users/takemore/ai/administrator/components/com_menus/src/Helper/MenusHelper.php (line 673)
MenusHelper::loadPreset()
in /usr/www/users/takemore/ai/administrator/modules/mod_menu/src/Menu/CssMenu.php (line 121)
CssMenu->load()
in /usr/www/users/takemore/ai/administrator/modules/mod_menu/mod_menu.php (line 19)
include('/usr/www/users/takemore/ai/administrator/modules/mod_menu/mod_menu.php')
in /usr/www/users/takemore/ai/libraries/src/Dispatcher/ModuleDispatcher.php (line 52)
ModuleDispatcher::Joomla\CMS\Dispatcher\{closure}()
in /usr/www/users/takemore/ai/libraries/src/Dispatcher/ModuleDispatcher.php (line 55)
ModuleDispatcher->dispatch()
in /usr/www/users/takemore/ai/libraries/src/Helper/ModuleHelper.php (line 291)
ModuleHelper::renderRawModule()
in /usr/www/users/takemore/ai/libraries/src/Helper/ModuleHelper.php (line 162)
ModuleHelper::renderModule()
in /usr/www/users/takemore/ai/libraries/src/Document/Renderer/Html/ModuleRenderer.php (line 99)
ModuleRenderer->render()
in /usr/www/users/takemore/ai/libraries/src/Document/Renderer/Html/ModulesRenderer.php (line 51)
ModulesRenderer->render()
in /usr/www/users/takemore/ai/libraries/src/Document/HtmlDocument.php (line 575)
HtmlDocument->getBuffer()
in /usr/www/users/takemore/ai/libraries/src/Document/HtmlDocument.php (line 894)
HtmlDocument->_renderTemplate()
in /usr/www/users/takemore/ai/libraries/src/Document/HtmlDocument.php (line 647)
HtmlDocument->render()
in /usr/www/users/takemore/ai/libraries/src/Document/ErrorDocument.php (line 139)
ErrorDocument->render()
in /usr/www/users/takemore/ai/libraries/src/Error/Renderer/HtmlRenderer.php (line 70)
HtmlRenderer->render()
in /usr/www/users/takemore/ai/libraries/src/Exception/ExceptionHandler.php (line 136)
ExceptionHandler::render()
in /usr/www/users/takemore/ai/libraries/src/Exception/ExceptionHandler.php (line 73)
ExceptionHandler::handleException()
in /usr/www/users/takemore/ai/libraries/src/Application/CMSApplication.php (line 336)
CMSApplication->execute()
in /usr/www/users/takemore/ai/administrator/includes/app.php (line 58)
require_once('/usr/www/users/takemore/ai/administrator/includes/app.php')
in /usr/www/users/takemore/ai/administrator/index.php (line 32)
mysqli_sql_exception
Unknown column 'a.ordering' in 'order clause'
in /usr/www/users/takemore/ai/libraries/vendor/joomla/database/src/Mysqli/MysqliStatement.php (line 138)
in /usr/www/users/takemore/ai/libraries/vendor/joomla/database/src/Mysqli/MysqliStatement.php -> prepare (line 138)
in /usr/www/users/takemore/ai/libraries/vendor/joomla/database/src/Mysqli/MysqliDriver.php -> __construct (line 1020)
in /usr/www/users/takemore/ai/libraries/vendor/joomla/database/src/DatabaseDriver.php -> prepareStatement (line 1785)
DatabaseDriver->setQuery()
in /usr/www/users/takemore/ai/administrator/components/com_menus/src/Helper/MenusHelper.php (line 816)
if ($iJoin) { $query->join('INNER', $iJoin); } $results = $db->setQuery($query)->loadObjectList(); // Skip the entire group if no items to iterate over. if ($results) { // Show the repeatable group heading node only if not set as hidden. if (!$hidden) {
MenusHelper::loadXml()
in /usr/www/users/takemore/ai/administrator/components/com_menus/src/Helper/MenusHelper.php (line 841)
MenusHelper::loadXml()
in /usr/www/users/takemore/ai/administrator/components/com_menus/src/Helper/MenusHelper.php (line 673)
MenusHelper::loadPreset()
in /usr/www/users/takemore/ai/administrator/modules/mod_menu/src/Menu/CssMenu.php (line 121)
CssMenu->load()
in /usr/www/users/takemore/ai/administrator/modules/mod_menu/mod_menu.php (line 19)
include('/usr/www/users/takemore/ai/administrator/modules/mod_menu/mod_menu.php')
in /usr/www/users/takemore/ai/libraries/src/Dispatcher/ModuleDispatcher.php (line 52)
ModuleDispatcher::Joomla\CMS\Dispatcher\{closure}()
in /usr/www/users/takemore/ai/libraries/src/Dispatcher/ModuleDispatcher.php (line 55)
ModuleDispatcher->dispatch()
in /usr/www/users/takemore/ai/libraries/src/Helper/ModuleHelper.php (line 291)
ModuleHelper::renderRawModule()
in /usr/www/users/takemore/ai/libraries/src/Helper/ModuleHelper.php (line 162)
ModuleHelper::renderModule()
in /usr/www/users/takemore/ai/libraries/src/Document/Renderer/Html/ModuleRenderer.php (line 99)
ModuleRenderer->render()
in /usr/www/users/takemore/ai/libraries/src/Document/Renderer/Html/ModulesRenderer.php (line 51)
ModulesRenderer->render()
in /usr/www/users/takemore/ai/libraries/src/Document/HtmlDocument.php (line 575)
HtmlDocument->getBuffer()
in /usr/www/users/takemore/ai/libraries/src/Document/HtmlDocument.php (line 894)
HtmlDocument->_renderTemplate()
in /usr/www/users/takemore/ai/libraries/src/Document/HtmlDocument.php (line 647)
HtmlDocument->render()
in /usr/www/users/takemore/ai/libraries/src/Application/CMSApplication.php (line 1073)
CMSApplication->render()
in /usr/www/users/takemore/ai/libraries/src/Application/AdministratorApplication.php (line 434)
AdministratorApplication->render()
in /usr/www/users/takemore/ai/libraries/src/Application/CMSApplication.php (line 311)
CMSApplication->execute()
in /usr/www/users/takemore/ai/administrator/includes/app.php (line 58)
require_once('/usr/www/users/takemore/ai/administrator/includes/app.php')
in /usr/www/users/takemore/ai/administrator/index.php (line 32)

I can provide an FPA post but it is too big for one post.
Its confidence rating was B.
If that is more useful than the errors please let me know.
Any help much appreciated. Bob

User avatar
ceford
Joomla! Hero
Joomla! Hero
Posts: 2744
Joined: Mon Feb 24, 2014 10:38 pm
Location: Edinburgh, Scotland
Contact:

Re: Can't access Admin panel after 4-5 upgrade

Post by ceford » Mon Apr 15, 2024 2:26 pm

Please open your administrator/logs/joomla_update.php file with a text editor and see what is there - especially at the end where any sql statements are located. It looks like one or more sql statements have not been executed.

Also, in System / Database - see if anything is reported there.

You may have to roll back to your previous backup.

BobShawAU
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Wed Sep 23, 2020 1:59 am

Re: Can't access Admin panel after 4-5 upgrade

Post by BobShawAU » Thu Apr 18, 2024 1:40 am

Thanks.
The last entry was way back in January
2024-01-13T06:14:21+00:00 INFO 123.243.203.15 update Update to version 4.4.2 is complete.
Looking like a rollback.

User avatar
Per Yngve Berg
Joomla! Master
Joomla! Master
Posts: 31030
Joined: Mon Oct 27, 2008 9:27 pm
Location: Romerike, Norway

Re: Can't access Admin panel after 4-5 upgrade

Post by Per Yngve Berg » Thu Apr 18, 2024 3:41 am

Mod. note: Relocated topic from Installation to the Upgrade Forum.

BobShawAU
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Wed Sep 23, 2020 1:59 am

Re: Can't access Admin panel after 4-5 upgrade

Post by BobShawAU » Fri May 17, 2024 1:30 am

Just an update on upgrading Joomla 4 to Joomla 5 and then can’t access the backend, with error Unknown column 'a.ordering’
This problem seems to be with a lot of users.

The solution is here https://gist.github.com/Yiannistaos/8e9 ... 8ca7d31e1c

Open PhpMyAdmin > SQL and type this:

ALTER TABLE `#__menu_types` ADD COLUMN `ordering` int NOT NULL DEFAULT 0 AFTER `client_id` /** CAN FAIL **/;
UPDATE `#__menu_types` SET `ordering` = `id` WHERE `client_id` = 0;
Changing #_ to the name of the table.

User avatar
ceford
Joomla! Hero
Joomla! Hero
Posts: 2744
Joined: Mon Feb 24, 2014 10:38 pm
Location: Edinburgh, Scotland
Contact:

Re: Can't access Admin panel after 4-5 upgrade

Post by ceford » Fri May 17, 2024 3:01 am

Did you roll back and reinstall? Check that you have table #__schemaorg - it is in the next sql file after the one that should have executed the statement you quoted.


Post Reply

Return to “Migrating and Upgrading to Joomla! 5.x”