1
0
mirror of synced 2024-12-15 23:56:02 +03:00
doctrine2/manual/codes/Working with objects - Component overview - RawSql - Adding components.php
2007-02-23 20:57:38 +00:00

14 lines
383 B
PHP

<?php
$query = new Doctrine_RawSql($conn);
$query->parseQuery("SELECT {entity.*}, {phonenumber.*}
FROM entity
LEFT JOIN phonenumber
ON phonenumber.entity_id = entity.id");
$query->addComponent("entity", "Entity");
$query->addComponent("phonenumber", "Entity.Phonenumber");
$entities = $query->execute();
?>