Details
-
Type:
Bug
-
Status:
Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: 1.2.1
-
Fix Version/s: None
-
Component/s: Record
-
Labels:None
Description
When you retrieve records like this:
(Here I have Labels, that have Albums)
$lab = Doctrine::getTable('Label')->createQuery('lab')
->leftJoin('lab.Albums alb')
->select('lab.id, alb.id')
->where('lab.id = ?', 1)
->fetchOne();
$lab->state() is STATE_PROXY : it's ok, properties are not all loaded from the DB and the object is not modified
BUT $lab->Albums[0]->state() is STATE_DIRTY : why ? the object is not modified...
This causes real problems, because this way, joined objects unloaded properties are corrupted : it really behaves like they all are "null", and that's all. Their real values are never loaded from the DB.
No way to correct that ?