Doctrine 2 - ORM
  1. Doctrine 2 - ORM
  2. DDC-1398

loading one item at a time when indexBy and EXTRA_LAZY fetch mode is used on a collection

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.4
    • Component/s: ORM
    • Security Level: All
    • Labels:
      None

      Description

      collection->get($key)

      Atm in 2.1.2 this is loading the entire collection. It would be really handy that it would extra lazy load only one item using the association and indexBy fields and given key value (if collection is not initialized and the key havent been loaded yet ofc)

      Am i making sense with this?

        Activity

        Hide
        Guilherme Blanco added a comment -

        Updating fix version

        Show
        Guilherme Blanco added a comment - Updating fix version
        Hide
        German Caseres added a comment -

        Is there any fix for this? i have the same problem.

        Show
        German Caseres added a comment - Is there any fix for this? i have the same problem.
        Hide
        Oleg Namaka added a comment - - edited

        It makes a perfect sense here, I wish it was possible, it would give us a room for even more optimization. Any input on the issue from the developers?

        Show
        Oleg Namaka added a comment - - edited It makes a perfect sense here, I wish it was possible, it would give us a room for even more optimization. Any input on the issue from the developers?
        Hide
        Sander Marechal added a comment -

        Any progress on this? I'd love to have get() that works on EXTRA_LAZY collections.

        Show
        Sander Marechal added a comment - Any progress on this? I'd love to have get() that works on EXTRA_LAZY collections.
        Hide
        Marco Pivetta added a comment -

        Sander Marechal pull requests are welcome

        Show
        Marco Pivetta added a comment - Sander Marechal pull requests are welcome
        Hide
        Sander Marechal added a comment -

        I'm on it I see the ORM is already in 2.4-RC stage. If my pull is accepted, can it still be included in 2.4 or will it have to wait until 2.5?

        Show
        Sander Marechal added a comment - I'm on it I see the ORM is already in 2.4-RC stage. If my pull is accepted, can it still be included in 2.4 or will it have to wait until 2.5?
        Hide
        Marco Pivetta added a comment -

        Sander Marechal no, it would need to wait for 2.5

        Show
        Marco Pivetta added a comment - Sander Marechal no, it would need to wait for 2.5
        Hide
        Sander Marechal added a comment -
        Show
        Sander Marechal added a comment - Ah, too bad. Anyway: https://github.com/doctrine/doctrine2/pull/706
        Hide
        Benjamin Eberlei added a comment -

        Merged for 2.4, we will release some more RCs

        Show
        Benjamin Eberlei added a comment - Merged for 2.4, we will release some more RCs

          People

          • Assignee:
            Benjamin Eberlei
            Reporter:
            Reio Piller
          • Votes:
            3 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: