#1465: Unhandled exception with bad DQL
-----------------------------------+----------------------------------------
Reporter: adam | Owner: romanb
Type: defect | Status: new
Priority: minor | Milestone:
Component: Query/Hydration | Version: 1.0
Keywords: | Has_test: 0
Mystatus: Pending Core Response | Has_patch: 0
-----------------------------------+----------------------------------------
A minor problem, but bad dql should be handled with exceptions rather than
php errors.
Here's the bad query.
I forgot to include the table reference for company: "Company c" vs.
"a.Company c"
$q = Doctrine_Query::create()->from('Address a, Company
c')->where('a.address_type_cid = ?', 'office');
And here are the php errors I got:
Notice: Undefined index: parent in
/usr/local/apache2/htdocs/fourAngle/2.0/trunk/plugins/sfDoctrine/lib/doctrine/Doctrine/Hydrator.php
on line 174
Notice: Undefined index: relation in
/usr/local/apache2/htdocs/fourAngle/2.0/trunk/plugins/sfDoctrine/lib/doctrine/Doctrine/Hydrator.php
on line 175
Notice: Undefined index: relation in
/usr/local/apache2/htdocs/fourAngle/2.0/trunk/plugins/sfDoctrine/lib/doctrine/Doctrine/Hydrator.php
on line 176
Fatal error: Call to a member function getAlias() on a non-object in
/usr/local/apache2/htdocs/fourAngle/2.0/trunk/plugins/sfDoctrine/lib/doctrine/Doctrine/Hydrator.php
on line 176
--
Ticket URL: <http://trac.doctrine-project.org/ticket/1465>
Doctrine <http://www.phpdoctrine.org>
PHP Doctrine Object Relational Mapper
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"doctrine-svn" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.co.uk/group/doctrine-svn?hl=en-GB
-~----------~----~----~----~------~----~------~--~---