OroPlatform Forums

Covering OroPlatform topics, including community updates and company announcements.

Forums Forums OroPlatform OroPlatform – How do I? Questions doctrine getResult() output is different than normal select sql

This topic contains 1 reply, has 2 voices, and was last updated by  Mike Kudelya 7 years, 2 months ago.

Starting from March 1, 2020 the forum has been switched to the read-only mode. Please head to StackOverflow for support.

  • Creator
    Topic
  • #36426

    bosumflici
    Participant

    Hi,

    I have this code in a controller:

    and this is the equivalent sql command from the debug log:

    The problem is that they are not returning the same result. For the above values the querybuilder return only 2 records, and the normal sql select command return 6 records. Of course the second one is the correct one!!!

    I cannot figure out why querybuilder returns different result for any values than the normal sql command.

    If someone can help i appreciate!
    PS: i tried getArrayResult() with no effect.

Viewing 1 replies (of 1 total)
  • Author
    Replies
  • #36427

    Mike Kudelya
    Participant

    Hi

    I can’t test you case, but try to understood on which step results will be the same when you start remove join and where. Are you sure that this sql is final and any acl restrictions don’t applied? Usually i get sql with getSQL function $qb->getQuery()->getSQL();

Viewing 1 replies (of 1 total)

The forum ‘OroPlatform – How do I? Questions’ is closed to new topics and replies.

Back to top