doctrine/orm · error · Exception
Unable to retrieve association information for column "%s"
Error message
Unable to retrieve association information for column "%s"
What it means
Error "Unable to retrieve association information for column "%s"" thrown in doctrine/orm.
Source
Thrown at src/Internal/Hydration/SimpleObjectHydrator.php:118
));
}
$discrMap = $this->class->discriminatorMap;
if (! isset($discrMap[$row[$discrColumnName]])) {
throw HydrationException::invalidDiscriminatorValue($row[$discrColumnName], array_keys($discrMap));
}
$entityName = $discrMap[$row[$discrColumnName]];
$discrColumnValue = $row[$discrColumnName];
unset($row[$discrColumnName]);
}
foreach ($row as $column => $value) {
// An ObjectHydrator should be used instead of SimpleObjectHydrator
if (isset($this->resultSetMapping()->relationMap[$column])) {
throw new Exception(sprintf('Unable to retrieve association information for column "%s"', $column));
}
$cacheKeyInfo = $this->hydrateColumnInfo($column);
if (! $cacheKeyInfo) {
continue;
}
// If we have inheritance in resultset, make sure the field belongs to the correct class
if (isset($cacheKeyInfo['discriminatorValues']) && ! in_array((string) $discrColumnValue, $cacheKeyInfo['discriminatorValues'], true)) {
continue;
}
// Check if value is null before conversion (because some types convert null to something else)
$valueIsNull = $value === null;
// Convert field to a valid PHP value
if (isset($cacheKeyInfo['type'])) {View on GitHub (pinned to d9b9ff7301)
When it happens
Trigger: Thrown at src/Internal/Hydration/SimpleObjectHydrator.php:118 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of doctrine/orm@d9b9ff7301 (2026-08-21).
Data as JSON: /api/errors/6ca338074cd4c0cf.
Report an issue: GitHub.