Joomla JTable & database changes: Joomla 3 → 4, 5 and 6

32 issues in this guide

Database access turns quiet J3 habits into hard fatals. This guide groups 32 entries: $db->query(), JDatabase, JDatabaseDriver, JDatabaseDriverMysqli, JDatabaseDriverPdo, JDatabaseDriverPgsql, JDatabaseQuery, JFactory::getDbo(), JTable, JTable::getInstance('Content'), and 22 more. Replacement has two layers. For tables, import Joomla\CMS\Table\Table (or the specific table class) and use the MVC / table factory instead of JTable::getInstance string lookups and observer subclasses. For queries, build with $db->getQuery(true), call execute() for writes and loadObjectList() / loadAssoc() for reads, and bind parameters instead of concatenating SQL. Schema scripts must ship InnoDB, NULL instead of '0000-00-00', and utf8mb4. Hop mix: 8 at Joomla 3 → 4; 24 at Joomla 5 → 6. Use each entry's before/after as the mechanical patch, then re-run installer SQL on a staging clone before you trust production data. Catalog replacements in this guide include $db->query() → $db->execute() / loadObjectList(); JDatabase → Joomla\Database\DatabaseDriver; JDatabaseDriver → Joomla\Database\DatabaseDriver; JDatabaseDriverMysqli → Joomla\Database\Mysqli\MysqliDriver. Open each h2 anchor for the full before/after, fix list, and error strings shipped in the reference data.

DB-QUERY-OLD-001

$db->query()

Old $db->query() API

On modern drivers, query() is not the execute API Joomla 3 tutorials taught. Use execute() for writes and load* for reads. Bind parameters instead of concatenating SQL.

$db->query() → $db->execute() / loadObjectList()

Dies at Joomla 3 → 4
Dies at Joomla 3 → 4J3: Works nativelyJ4: Changed behaviourJ6: Changed behaviourBC plugin: not applicablePatch possible — review itDatabase API

What you will see

  • Call to undefined method ...::query()
  • Database query failed

Symptoms people search

sql concat 500 · query() undefined

Replace this code

Swap $db->query() for $db->execute() / loadObjectList().

Joomla 3

Remove or stop calling this

$db->setQuery($sql);
$db->query();
$rows = $db->loadObjectList();

Joomla 4 / 6

Use this instead

$db->setQuery($query);
$db->execute();
$rows = $db->loadObjectList();

How to fix it

  1. 1Build queries with $db->getQuery(true).
  2. 2Use quoteName / bind.
  3. 3Never interpolate $_GET into SQL.

Also known as

query() · execute() · bind

JDATABASE-CLASS-001

JDatabase

JDatabase class name

JDatabase is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JDatabase" not found.

JDatabase → Joomla\Database\DatabaseDriver

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameDatabase API

What you will see

  • Class "JDatabase" not found
  • Class 'JDatabase' not found
  • Failed to open stream: JDatabase

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JDatabase for Joomla\Database\DatabaseDriver.

Joomla 3

Remove or stop calling this

JDatabase::getInstance();
// or new JDatabase()

Joomla 4 / 6

Use this instead

use Joomla\Database\DatabaseDriver;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\Database\DatabaseDriver.
  2. 2Replace every JDatabase with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JDatabase · Joomla\Database\DatabaseDriver · class alias · J prefix

JDATABASEDRIVER-CLASS-001

JDatabaseDriver

JDatabaseDriver class name

JDatabaseDriver is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JDatabaseDriver" not found.

JDatabaseDriver → Joomla\Database\DatabaseDriver

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameDatabase API

What you will see

  • Class "JDatabaseDriver" not found
  • Class 'JDatabaseDriver' not found
  • Failed to open stream: JDatabaseDriver

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JDatabaseDriver for Joomla\Database\DatabaseDriver.

Joomla 3

Remove or stop calling this

JDatabaseDriver::getInstance();
// or new JDatabaseDriver()

Joomla 4 / 6

Use this instead

use Joomla\Database\DatabaseDriver;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\Database\DatabaseDriver.
  2. 2Replace every JDatabaseDriver with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JDatabaseDriver · Joomla\Database\DatabaseDriver · class alias · J prefix

JDATABASEMYSQLI-CLASS-001

JDatabaseDriverMysqli

JDatabaseDriverMysqli class name

JDatabaseDriverMysqli is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JDatabaseDriverMysqli" not found.

JDatabaseDriverMysqli → Joomla\Database\Mysqli\MysqliDriver

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameDatabase API

What you will see

  • Class "JDatabaseDriverMysqli" not found
  • Class 'JDatabaseDriverMysqli' not found
  • Failed to open stream: JDatabaseDriverMysqli

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JDatabaseDriverMysqli for Joomla\Database\Mysqli\MysqliDriver.

Joomla 3

Remove or stop calling this

JDatabaseDriverMysqli::getInstance();
// or new JDatabaseDriverMysqli()

Joomla 4 / 6

Use this instead

use Joomla\Database\Mysqli\MysqliDriver;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\Database\Mysqli\MysqliDriver.
  2. 2Replace every JDatabaseDriverMysqli with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JDatabaseDriverMysqli · Joomla\Database\Mysqli\MysqliDriver · class alias · J prefix

JDATABASEPDO-CLASS-001

JDatabaseDriverPdo

JDatabaseDriverPdo class name

JDatabaseDriverPdo is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JDatabaseDriverPdo" not found.

JDatabaseDriverPdo → Joomla\Database\Pdo\PdoDriver

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameDatabase API

What you will see

  • Class "JDatabaseDriverPdo" not found
  • Class 'JDatabaseDriverPdo' not found
  • Failed to open stream: JDatabaseDriverPdo

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JDatabaseDriverPdo for Joomla\Database\Pdo\PdoDriver.

Joomla 3

Remove or stop calling this

JDatabaseDriverPdo::getInstance();
// or new JDatabaseDriverPdo()

Joomla 4 / 6

Use this instead

use Joomla\Database\Pdo\PdoDriver;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\Database\Pdo\PdoDriver.
  2. 2Replace every JDatabaseDriverPdo with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JDatabaseDriverPdo · Joomla\Database\Pdo\PdoDriver · class alias · J prefix

JDATABASEPGSQL-CLASS-001

JDatabaseDriverPgsql

JDatabaseDriverPgsql class name

JDatabaseDriverPgsql is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JDatabaseDriverPgsql" not found.

JDatabaseDriverPgsql → Joomla\Database\Pgsql\PgsqlDriver

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameDatabase API

What you will see

  • Class "JDatabaseDriverPgsql" not found
  • Class 'JDatabaseDriverPgsql' not found
  • Failed to open stream: JDatabaseDriverPgsql

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JDatabaseDriverPgsql for Joomla\Database\Pgsql\PgsqlDriver.

Joomla 3

Remove or stop calling this

JDatabaseDriverPgsql::getInstance();
// or new JDatabaseDriverPgsql()

Joomla 4 / 6

Use this instead

use Joomla\Database\Pgsql\PgsqlDriver;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\Database\Pgsql\PgsqlDriver.
  2. 2Replace every JDatabaseDriverPgsql with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JDatabaseDriverPgsql · Joomla\Database\Pgsql\PgsqlDriver · class alias · J prefix

JDATABASEQUERY-CLASS-001

JDatabaseQuery

JDatabaseQuery class name

JDatabaseQuery is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JDatabaseQuery" not found.

JDatabaseQuery → Joomla\Database\DatabaseQuery

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameDatabase API

What you will see

  • Class "JDatabaseQuery" not found
  • Class 'JDatabaseQuery' not found
  • Failed to open stream: JDatabaseQuery

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JDatabaseQuery for Joomla\Database\DatabaseQuery.

Joomla 3

Remove or stop calling this

JDatabaseQuery::getInstance();
// or new JDatabaseQuery()

Joomla 4 / 6

Use this instead

use Joomla\Database\DatabaseQuery;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\Database\DatabaseQuery.
  2. 2Replace every JDatabaseQuery with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JDatabaseQuery · Joomla\Database\DatabaseQuery · class alias · J prefix

JFACTORY-GETDBO-001

JFactory::getDbo()

Factory::getDbo() / getDBO()

getDbo() is a service locator. Joomla wants the database from the DI container. Core has deferred the fatal removal toward Joomla 7, but a native Joomla 6 extension should not ship getDbo().

JFactory::getDbo() → $this->getDatabase() or Factory::getContainer()->get(DatabaseInterface::class)

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Deprecated — do not shipJ6: Deprecated — do not shipBC plugin: not applicablePatch possible — review itDatabase API

What you will see

  • Factory::getDbo() is deprecated
  • Joomla\CMS\Factory::getDbo is deprecated

Symptoms people search

deprecation log filled with getDbo · database calls still using Factory

Replace this code

Swap JFactory::getDbo() for $this->getDatabase() or Factory::getContainer()->get(DatabaseInterface::class).

Joomla 3

Remove or stop calling this

$db = JFactory::getDbo();
$db = Factory::getDbo();

Joomla 4 / 6

Use this instead

use Joomla\CMS\Factory;
use Joomla\Database\DatabaseInterface;

$db = Factory::getContainer()->get(DatabaseInterface::class);
// Inside a model: $db = $this->getDatabase();

How to fix it

  1. 1In models, use $this->getDatabase().
  2. 2Elsewhere, get DatabaseInterface from the container.
  3. 3Replace $db->query() (old) with execute() / loadObjectList().

Also known as

getDbo · getDBO · dbo · DatabaseInterface

JTABLE-CLASS-001

JTable

JTable class name

JTable is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTable" not found.

JTable → Joomla\CMS\Table\Table

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTable" not found
  • Class 'JTable' not found
  • Failed to open stream: JTable

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTable for Joomla\CMS\Table\Table.

Joomla 3

Remove or stop calling this

JTable::getInstance();
// or new JTable()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Table;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Table.
  2. 2Replace every JTable with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTable · Joomla\CMS\Table\Table · class alias · J prefix

JTABLE-GETINSTANCE-001

JTable::getInstance('Content')

Table::getInstance()

String-based getInstance is deprecated. Namespaced tables should come from the component factory.

JTable::getInstance('Content') → MVC / Table factory

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Deprecated — do not shipJ6: Deprecated — do not shipBC plugin: not applicablePatch possible — review itMVC

What you will see

  • Table class not found

Symptoms people search

cannot store row after namespace move

Replace this code

Swap JTable::getInstance('Content') for MVC / Table factory.

Joomla 3

Remove or stop calling this

$table = JTable::getInstance('LmsCourse', 'Table');

Joomla 4 / 6

Use this instead

$table = $this->getTable('Course');
// or the MVC factory table method

How to fix it

  1. 1Use $this->getTable() in models.
  2. 2Register the table with MVC Factory.

Also known as

JTable::getInstance · getTable

JTABLEASSET-CLASS-001

JTableAsset

JTableAsset class name

JTableAsset is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableAsset" not found.

JTableAsset → Joomla\CMS\Table\Asset

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableAsset" not found
  • Class 'JTableAsset' not found
  • Failed to open stream: JTableAsset

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableAsset for Joomla\CMS\Table\Asset.

Joomla 3

Remove or stop calling this

JTableAsset::getInstance();
// or new JTableAsset()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Asset;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Asset.
  2. 2Replace every JTableAsset with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableAsset · Joomla\CMS\Table\Asset · class alias · J prefix

JTABLECATEGORY-CLASS-001

JTableCategory

JTableCategory class name

JTableCategory is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableCategory" not found.

JTableCategory → Joomla\CMS\Table\Category

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableCategory" not found
  • Class 'JTableCategory' not found
  • Failed to open stream: JTableCategory

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableCategory for Joomla\CMS\Table\Category.

Joomla 3

Remove or stop calling this

JTableCategory::getInstance();
// or new JTableCategory()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Category;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Category.
  2. 2Replace every JTableCategory with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableCategory · Joomla\CMS\Table\Category · class alias · J prefix

JTABLECONTENT-CLASS-001

JTableContent

JTableContent class name

JTableContent is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableContent" not found.

JTableContent → Joomla\CMS\Table\Content

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableContent" not found
  • Class 'JTableContent' not found
  • Failed to open stream: JTableContent

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableContent for Joomla\CMS\Table\Content.

Joomla 3

Remove or stop calling this

JTableContent::getInstance();
// or new JTableContent()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Content;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Content.
  2. 2Replace every JTableContent with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableContent · Joomla\CMS\Table\Content · class alias · J prefix

JTABLECONTENTTYPE-CLASS-001

JTableContenttype

JTableContenttype class name

JTableContenttype is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableContenttype" not found.

JTableContenttype → Joomla\CMS\Table\ContentType

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableContenttype" not found
  • Class 'JTableContenttype' not found
  • Failed to open stream: JTableContenttype

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableContenttype for Joomla\CMS\Table\ContentType.

Joomla 3

Remove or stop calling this

JTableContenttype::getInstance();
// or new JTableContenttype()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\ContentType;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\ContentType.
  2. 2Replace every JTableContenttype with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableContenttype · Joomla\CMS\Table\ContentType · class alias · J prefix

JTABLEEXTENSION-CLASS-001

JTableExtension

JTableExtension class name

JTableExtension is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableExtension" not found.

JTableExtension → Joomla\CMS\Table\Extension

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableExtension" not found
  • Class 'JTableExtension' not found
  • Failed to open stream: JTableExtension

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableExtension for Joomla\CMS\Table\Extension.

Joomla 3

Remove or stop calling this

JTableExtension::getInstance();
// or new JTableExtension()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Extension;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Extension.
  2. 2Replace every JTableExtension with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableExtension · Joomla\CMS\Table\Extension · class alias · J prefix

JTABLELANGUAGE-CLASS-001

JTableLanguage

JTableLanguage class name

JTableLanguage is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableLanguage" not found.

JTableLanguage → Joomla\CMS\Table\Language

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableLanguage" not found
  • Class 'JTableLanguage' not found
  • Failed to open stream: JTableLanguage

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableLanguage for Joomla\CMS\Table\Language.

Joomla 3

Remove or stop calling this

JTableLanguage::getInstance();
// or new JTableLanguage()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Language;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Language.
  2. 2Replace every JTableLanguage with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableLanguage · Joomla\CMS\Table\Language · class alias · J prefix

JTABLEMENU-CLASS-001

JTableMenu

JTableMenu class name

JTableMenu is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableMenu" not found.

JTableMenu → Joomla\CMS\Table\Menu

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableMenu" not found
  • Class 'JTableMenu' not found
  • Failed to open stream: JTableMenu

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableMenu for Joomla\CMS\Table\Menu.

Joomla 3

Remove or stop calling this

JTableMenu::getInstance();
// or new JTableMenu()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Menu;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Menu.
  2. 2Replace every JTableMenu with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableMenu · Joomla\CMS\Table\Menu · class alias · J prefix

JTABLEMENUTYPE-CLASS-001

JTableMenuType

JTableMenuType class name

JTableMenuType is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableMenuType" not found.

JTableMenuType → Joomla\CMS\Table\MenuType

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableMenuType" not found
  • Class 'JTableMenuType' not found
  • Failed to open stream: JTableMenuType

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableMenuType for Joomla\CMS\Table\MenuType.

Joomla 3

Remove or stop calling this

JTableMenuType::getInstance();
// or new JTableMenuType()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\MenuType;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\MenuType.
  2. 2Replace every JTableMenuType with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableMenuType · Joomla\CMS\Table\MenuType · class alias · J prefix

JTABLEMODULE-CLASS-001

JTableModule

JTableModule class name

JTableModule is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableModule" not found.

JTableModule → Joomla\CMS\Table\Module

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableModule" not found
  • Class 'JTableModule' not found
  • Failed to open stream: JTableModule

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableModule for Joomla\CMS\Table\Module.

Joomla 3

Remove or stop calling this

JTableModule::getInstance();
// or new JTableModule()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Module;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Module.
  2. 2Replace every JTableModule with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableModule · Joomla\CMS\Table\Module · class alias · J prefix

JTABLENESTED-CLASS-001

JTableNested

JTableNested class name

JTableNested is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableNested" not found.

JTableNested → Joomla\CMS\Table\Nested

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableNested" not found
  • Class 'JTableNested' not found
  • Failed to open stream: JTableNested

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableNested for Joomla\CMS\Table\Nested.

Joomla 3

Remove or stop calling this

JTableNested::getInstance();
// or new JTableNested()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Nested;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Nested.
  2. 2Replace every JTableNested with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableNested · Joomla\CMS\Table\Nested · class alias · J prefix

JTABLEOBSERVER-001

JTableObserverTags

JTableObserver*

Observer attach on tables was replaced by plugins.

JTableObserverTags → Core plugins (tags, content history) — do not subclass observers

Dies at Joomla 3 → 4
Dies at Joomla 3 → 4J3: Works nativelyJ4: Removed — fatalJ6: Removed — fatalBC plugin: no — already dead on J4Architecture change — no auto-fixMVC

What you will see

  • Class "JTableObserver" not found
  • Class "JTableObserverTags" not found

Symptoms people search

tags not saving on custom table

Replace this code

Swap JTableObserverTags for Core plugins (tags, content history) — do not subclass observers.

Joomla 3

Remove or stop calling this

class JTableObserverTags extends JTableObserver {}

Joomla 4 / 6

Use this instead

Use the tags and history plugins. Table observers were removed.

How to fix it

  1. 1Remove custom JTableObserver subclasses.
  2. 2Listen to onTable* events if you must hook store().

Also known as

JTableObserver · JTableObserverContenthistory

There is no 1:1 swap for this one. The architecture changed. If you cannot rewrite it, Infyways can.

JTABLESESSION-CLASS-001

JTableSession

JTableSession class name

JTableSession is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableSession" not found.

JTableSession → Joomla\CMS\Table\Session

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableSession" not found
  • Class 'JTableSession' not found
  • Failed to open stream: JTableSession

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableSession for Joomla\CMS\Table\Session.

Joomla 3

Remove or stop calling this

JTableSession::getInstance();
// or new JTableSession()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Session;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Session.
  2. 2Replace every JTableSession with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableSession · Joomla\CMS\Table\Session · class alias · J prefix

JTABLEUPDATE-CLASS-001

JTableUpdate

JTableUpdate class name

JTableUpdate is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableUpdate" not found.

JTableUpdate → Joomla\CMS\Table\Update

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableUpdate" not found
  • Class 'JTableUpdate' not found
  • Failed to open stream: JTableUpdate

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableUpdate for Joomla\CMS\Table\Update.

Joomla 3

Remove or stop calling this

JTableUpdate::getInstance();
// or new JTableUpdate()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Update;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Update.
  2. 2Replace every JTableUpdate with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableUpdate · Joomla\CMS\Table\Update · class alias · J prefix

JTABLEUSER-CLASS-001

JTableUser

JTableUser class name

JTableUser is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableUser" not found.

JTableUser → Joomla\CMS\Table\User

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableUser" not found
  • Class 'JTableUser' not found
  • Failed to open stream: JTableUser

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableUser for Joomla\CMS\Table\User.

Joomla 3

Remove or stop calling this

JTableUser::getInstance();
// or new JTableUser()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\User;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\User.
  2. 2Replace every JTableUser with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableUser · Joomla\CMS\Table\User · class alias · J prefix

JTABLEUSERGROUP-CLASS-001

JTableUsergroup

JTableUsergroup class name

JTableUsergroup is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableUsergroup" not found.

JTableUsergroup → Joomla\CMS\Table\Usergroup

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableUsergroup" not found
  • Class 'JTableUsergroup' not found
  • Failed to open stream: JTableUsergroup

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableUsergroup for Joomla\CMS\Table\Usergroup.

Joomla 3

Remove or stop calling this

JTableUsergroup::getInstance();
// or new JTableUsergroup()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\Usergroup;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\Usergroup.
  2. 2Replace every JTableUsergroup with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableUsergroup · Joomla\CMS\Table\Usergroup · class alias · J prefix

JTABLEVIEWLEVEL-CLASS-001

JTableViewlevel

JTableViewlevel class name

JTableViewlevel is a Joomla 3 global class. Joomla 4 still has an alias. Joomla 5 needs the Behaviour – Backward Compatibility plugin. Native Joomla 6 does not load that alias — you get Class "JTableViewlevel" not found.

JTableViewlevel → Joomla\CMS\Table\ViewLevel

Dies at Joomla 5 → 6
Dies at Joomla 5 → 6J3: Works nativelyJ4: Alias (old name still resolves)J6: Removed — fatalBC plugin: covers the class nameMechanical renameMVC

What you will see

  • Class "JTableViewlevel" not found
  • Class 'JTableViewlevel' not found
  • Failed to open stream: JTableViewlevel

Symptoms people search

white screen after disabling compatibility plugin · class not found on Joomla 6 · works on Joomla 5 until I turn off backward compatibility

Replace this code

Swap JTableViewlevel for Joomla\CMS\Table\ViewLevel.

Joomla 3

Remove or stop calling this

JTableViewlevel::getInstance();
// or new JTableViewlevel()

Joomla 4 / 6

Use this instead

use Joomla\CMS\Table\ViewLevel;

// Call the namespaced class. Do not keep the J prefix.

How to fix it

  1. 1Add a use statement for Joomla\CMS\Table\ViewLevel.
  2. 2Replace every JTableViewlevel with the short class name from that use line.
  3. 3Disable Behaviour – Backward Compatibility on a Joomla 5 staging site. If it fatals, this class is still in the code.

Also known as

JTableViewlevel · Joomla\CMS\Table\ViewLevel · class alias · J prefix

SQL-BIND-001

$db->setQuery('SELECT * FROM #__lms WHERE id = ' . $id)

String-concat SQL instead of bind()

Concat still “works”. It is SQL injection with extra steps. Joomla 4+ query objects support bind(). Migrations should stop interpolating.

$db->setQuery('SELECT * FROM #__lms WHERE id = ' . $id) → $query->bind() / quoteName + bind

Dies at Joomla 3 → 4
Dies at Joomla 3 → 4J3: Works nativelyJ4: Works nativelyJ6: Works nativelyBC plugin: not applicablePatch possible — review itDatabase API

Symptoms people search

sql injection · setQuery concat · bind parameters

Replace this code

Swap $db->setQuery('SELECT * FROM #__lms WHERE id = ' . $id) for $query->bind() / quoteName + bind.

Joomla 3

Remove or stop calling this

$db->setQuery('SELECT * FROM #__lms WHERE id = ' . (int) $id);

Joomla 4 / 6

Use this instead

$query = $db->getQuery(true)
    ->select('*')
    ->from($db->quoteName('#__lms'))
    ->where($db->quoteName('id') . ' = :id')
    ->bind(':id', $id, ParameterType::INTEGER);
$db->setQuery($query);

How to fix it

  1. 1Use getQuery(true), quoteName, and bind().
  2. 2Never setQuery() a string built from request data.

Also known as

bind() · quoteName · setQuery · #__

SQL-DROP-NO-EXISTS-001

DROP TABLE `#__lms_old`;

DROP TABLE without IF EXISTS

Reinstall and update SQL fail hard if the table is already gone. Joomla 4 installers expect IF EXISTS.

DROP TABLE `#__lms_old`; → DROP TABLE IF EXISTS `#__lms_old`;

Dies at Joomla 3 → 4
Dies at Joomla 3 → 4J3: Works nativelyJ4: Removed — fatalJ6: Removed — fatalBC plugin: no — already dead on J4Mechanical renameSQL / schema

What you will see

  • SQLSTATE[42S02]
  • Table doesn't exist

Symptoms people search

uninstall sql error · DROP TABLE

Replace this code

Swap DROP TABLE `#__lms_old`; for DROP TABLE IF EXISTS `#__lms_old`;.

Joomla 3

Remove or stop calling this

DROP TABLE `#__lms_courses`;

Joomla 4 / 6

Use this instead

DROP TABLE IF EXISTS `#__lms_courses`;

How to fix it

  1. 1Add IF EXISTS to every DROP in install/uninstall SQL.

Also known as

DROP TABLE · IF EXISTS

SQL-MYISAM-001

ENGINE=MyISAM

MyISAM engine in install SQL

Joomla 4+ expects InnoDB. MyISAM cannot do foreign keys and is a poor default on modern MySQL.

ENGINE=MyISAM → ENGINE=InnoDB

Dies at Joomla 3 → 4
Dies at Joomla 3 → 4J3: Works nativelyJ4: Changed behaviourJ6: Changed behaviourBC plugin: not applicableMechanical renameSQL / schema

Symptoms people search

foreign keys fail · install sql mysql 8 warning

Replace this code

Swap ENGINE=MyISAM for ENGINE=InnoDB.

Joomla 3

Remove or stop calling this

CREATE TABLE `#__lms_courses` (...) ENGINE=MyISAM DEFAULT CHARSET=utf8;

Joomla 4 / 6

Use this instead

CREATE TABLE `#__lms_courses` (...) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

How to fix it

  1. 1Replace MyISAM with InnoDB in install and update SQL.
  2. 2Prefer utf8mb4.

Also known as

MyISAM · InnoDB

SQL-SQLSERVER-001

sqlsrv

SQL Server driver

Joomla 4 dropped SQL Server. There is no compatibility plugin for this.

sqlsrv → MySQL / MariaDB / PostgreSQL

Dies at Joomla 3 → 4
Dies at Joomla 3 → 4J3: Works nativelyJ4: Removed — fatalJ6: Removed — fatalBC plugin: no — already dead on J4Architecture change — no auto-fixSQL / schema

What you will see

  • Database driver not available
  • Could not connect to the database

Symptoms people search

joomla 4 installer will not accept sql server

Replace this code

Swap sqlsrv for MySQL / MariaDB / PostgreSQL.

Joomla 3

Remove or stop calling this

public $dbtype = 'sqlsrv';

Joomla 4 / 6

Use this instead

Move the site to MySQL 8 / MariaDB / PostgreSQL. SQL Server is not a Joomla 4+ driver.

How to fix it

  1. 1Plan a database migration to MySQL or PostgreSQL before the Joomla 4 hop.

Also known as

SQL Server · sqlsrv · mssql

There is no 1:1 swap for this one. The architecture changed. If you cannot rewrite it, Infyways can.

SQL-UTF8MB4-001

DEFAULT CHARSET=utf8

utf8 (3-byte) instead of utf8mb4

Joomla 4+ and MySQL 8 expect utf8mb4. Plain utf8 cannot store emoji and some names.

DEFAULT CHARSET=utf8 → DEFAULT CHARSET=utf8mb4

Dies at Joomla 3 → 4
Dies at Joomla 3 → 4J3: Works nativelyJ4: Changed behaviourJ6: Changed behaviourBC plugin: not applicableMechanical renameSQL / schema

What you will see

  • Incorrect string value

Symptoms people search

emoji becomes ??? · utf8 charset

Replace this code

Swap DEFAULT CHARSET=utf8 for DEFAULT CHARSET=utf8mb4.

Joomla 3

Remove or stop calling this

CREATE TABLE `#__lms` (...) ENGINE=InnoDB DEFAULT CHARSET=utf8;

Joomla 4 / 6

Use this instead

CREATE TABLE `#__lms` (...) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

How to fix it

  1. 1Use utf8mb4 in CREATE TABLE.
  2. 2Convert existing tables with a planned ALTER (backup first).

Also known as

utf8mb4 · CHARSET=utf8

SQL-ZERO-DATE-001

'0000-00-00 00:00:00'

0000-00-00 dates

MySQL strict mode (the Joomla 4+ default) rejects the zero date. Inserts and upgrades fail with Incorrect DATETIME value.

'0000-00-00 00:00:00' → NULL

Dies at Joomla 3 → 4
Dies at Joomla 3 → 4J3: Works nativelyJ4: Removed — fatalJ6: Removed — fatalBC plugin: no — already dead on J4Patch possible — review itSQL / schema

What you will see

  • Incorrect DATETIME value: '0000-00-00 00:00:00'
  • Incorrect DATE value: '0000-00-00'

Symptoms people search

cannot save article · install sql fails on mysql 8 · zero date

Replace this code

Swap '0000-00-00 00:00:00' for NULL.

Joomla 3

Remove or stop calling this

`created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00'

Joomla 4 / 6

Use this instead

`created` datetime NULL DEFAULT NULL

How to fix it

  1. 1Change columns to NULL default NULL.
  2. 2Stop writing '0000-00-00' from PHP — use null.
  3. 3UPDATE existing rows to NULL before the schema change if needed.

Also known as

0000-00-00 · zero date · invalid datetime

Start a project

Have something
to build?

Tell us what you are building. You will hear back from an engineer within one business day.

hello@infyways.com · Remote, working across time zones

Tell us about your project

Fill out the quick form and we'll reach out.