DDC-3658: [GH-1365] fix rare query test failures due to nondeterminism without order by clause #4494

Closed
opened 2026-01-22 14:42:51 +01:00 by admin · 3 comments
Owner

Originally created by @doctrinebot on GitHub (Apr 3, 2015).

Originally assigned to: @Ocramius on GitHub.

Jira issue originally created by user @doctrinebot:

This issue is created automatically through a Github pull request on behalf of zeroedin-bill:

Url: https://github.com/doctrine/doctrine2/pull/1365

Message:

I was wondering why this travis testrun failed. I investigated and found that the queries involved did not have order by clauses, but were assuming that the query result would return in the same order in which the records were persisted. This is not guaranteed to be the case on most RDBs.

This PR simply adds an order by clause to the queries that will produce a deterministic result and prevent spurious test failures.

Originally created by @doctrinebot on GitHub (Apr 3, 2015). Originally assigned to: @Ocramius on GitHub. Jira issue originally created by user @doctrinebot: This issue is created automatically through a Github pull request on behalf of zeroedin-bill: Url: https://github.com/doctrine/doctrine2/pull/1365 Message: I was wondering why [this travis testrun](https://travis-ci.org/doctrine/doctrine2/jobs/57045280) failed. I investigated and found that the queries involved did not have order by clauses, but were assuming that the query result would return in the same order in which the records were persisted. This is not guaranteed to be the case on most RDBs. This PR simply adds an order by clause to the queries that will produce a deterministic result and prevent spurious test failures.
admin added the Bug label 2026-01-22 14:42:51 +01:00
admin closed this issue 2026-01-22 14:42:52 +01:00
Author
Owner

@doctrinebot commented on GitHub (Apr 4, 2015):

Comment created by @doctrinebot:

A related Github Pull-Request [GH-1365] was assigned:
https://github.com/doctrine/doctrine2/pull/1365

@doctrinebot commented on GitHub (Apr 4, 2015): Comment created by @doctrinebot: A related Github Pull-Request [GH-1365] was assigned: https://github.com/doctrine/doctrine2/pull/1365
Author
Owner

@doctrinebot commented on GitHub (Apr 4, 2015):

Comment created by @doctrinebot:

A related Github Pull-Request [GH-1365] was closed:
https://github.com/doctrine/doctrine2/pull/1365

@doctrinebot commented on GitHub (Apr 4, 2015): Comment created by @doctrinebot: A related Github Pull-Request [GH-1365] was closed: https://github.com/doctrine/doctrine2/pull/1365
Author
Owner

@doctrinebot commented on GitHub (Apr 4, 2015):

Issue was closed with resolution "Fixed"

@doctrinebot commented on GitHub (Apr 4, 2015): 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#4494