mirror of
https://github.com/doctrine/orm.git
synced 2026-03-24 06:52:09 +01:00
Error for delete query without alias since 2.6.0 #5823
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @dmaicher on GitHub (Dec 26, 2017).
Originally assigned to: @lcobucci on GitHub.
This used to work with
2.5.x:Now with
2.6.0I get this error:If I add an alias it works again:
Is this BC break intentional?
@Majkl578 commented on GitHub (Dec 26, 2017):
Similar to #6932 (missing alias in SELECT, here it's FROM), it'll be caused by the same source.
As you can see here in EBNF for 2.5.0, alias is actually supposed to be mandatory.
It should probably be fixed for 2.6.
@Tobion commented on GitHub (Jan 7, 2018):
Can confirm the bug. I'm als affected with something like
$em->createQuery('DELETE FROM '.MyEntity::class)->execute();.I don't think the alias should be required for simple queries like this.
@lcobucci commented on GitHub (Feb 18, 2018):
#7077 is fixing the BC-break and discussing the update of the grammar to align with JPA 2.2 for
v2.6.xandv3.0@Ocramius commented on GitHub (Feb 19, 2018):
Handled in #7077