DDC-820: Nullable associations combined with a column definition generates a notice #1013

Closed
opened 2026-01-22 12:58:53 +01:00 by admin · 2 comments
Owner

Originally created by @doctrinebot on GitHub (Sep 29, 2010).

Jira issue originally created by user hasbridge:

When an entity has an optional association on a given field and also a column definition on that field, loading that entity generates a notice in UnitOfWork.php on line 1884. Other than the notice, the code works fine. This is the line:

$joinColumnValue = $data[$srcColumn];

Suggested fix:

$joinColumnValue = isset($data[$srcColumn]) ? $data[$srcColumn] : null;

I have attached a test case which reproduces the issue.

Originally created by @doctrinebot on GitHub (Sep 29, 2010). Jira issue originally created by user hasbridge: When an entity has an optional association on a given field and also a column definition on that field, loading that entity generates a notice in UnitOfWork.php on line 1884. Other than the notice, the code works fine. This is the line: `$joinColumnValue = $data[$srcColumn];` Suggested fix: `$joinColumnValue = isset($data[$srcColumn]) ? $data[$srcColumn] : null;` I have attached a test case which reproduces the issue.
admin added the Bug label 2026-01-22 12:58:53 +01:00
admin closed this issue 2026-01-22 12:58:53 +01:00
Author
Owner

@doctrinebot commented on GitHub (Sep 29, 2010):

Comment created by @beberlei:

This is already fixed in master, will be in RC1.

@doctrinebot commented on GitHub (Sep 29, 2010): Comment created by @beberlei: This is already fixed in master, will be in RC1.
Author
Owner

@doctrinebot commented on GitHub (Sep 29, 2010):

Issue was closed with resolution "Fixed"

@doctrinebot commented on GitHub (Sep 29, 2010): Issue was closed with resolution "Fixed"
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: doctrine/archived-orm#1013