Skip to content

Commit

Permalink
[TASK] Avoid deprecated SchemaManager->listTableDetails() method
Browse files Browse the repository at this point in the history
Doctrine DBAL deprecated `SchemaManager->listTableDetails()`
within `3.x` [1]. That means that this method will be removed
with `doctrine/dbal 4.x`.

To pave the way towards the next `doctrine/dbal` major version,
the usage is replaced with the `SchemaManager->introspectTable()`
method.

[1] https://github.com/doctrine/dbal/blob/3.7.x/UPGRADE.md#deprecated-abstractschemamanager-schema-introspection-methods

Releases: main
  • Loading branch information
sbuerk committed Nov 21, 2023
1 parent ac78c77 commit d2f29b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Classes/Core/Functional/Framework/DataHandling/DataSet.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ public static function import(string $path): void
$connection = GeneralUtility::makeInstance(ConnectionPool::class)->getConnectionForTable($tableName);
$platform = $connection->getDatabasePlatform();
// @todo Check if we can use the cached schema information here instead.
$tableDetails = $connection->createSchemaManager()->listTableDetails($tableName);
$tableDetails = $connection->createSchemaManager()->introspectTable($tableName);
foreach ($dataSet->getElements($tableName) as $element) {
// Some DBMS like postgresql are picky about inserting blob types with correct cast, setting
// types correctly (like Connection::PARAM_LOB) allows doctrine to create valid SQL
Expand Down

0 comments on commit d2f29b6

Please sign in to comment.