Skip to content

Commit

Permalink
Also consider database schema when retrieving AUTO_INCREMENT value (D…
Browse files Browse the repository at this point in the history
  • Loading branch information
bramstroker authored Mar 6, 2020
1 parent 85fac06 commit 080bd6b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Listeners/AttributeSet/NameResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ public function getNextPimcoreAttributeSetName(): string
->from(
'information_schema.TABLES',
'AUTO_INCREMENT'
)->where('TABLE_NAME = ?', $connection->getTableName('eav_attribute_set'));
)->where('TABLE_NAME = ?', $connection->getTableName('eav_attribute_set')
)->where('TABLE_SCHEMA = ?', $this->resource->getSchemaName(ResourceConnection::DEFAULT_CONNECTION));

return sprintf('pimcore-set-%s', (int)$connection->fetchOne($query));
}
Expand Down

0 comments on commit 080bd6b

Please sign in to comment.