Skip to content

Loading…

DDC-2314: getResults with numeric indexes for fields #3018

Open
doctrinebot opened this Issue · 0 comments

2 participants

@doctrinebot

Jira issue originally created by user ninjds:

When executing a simple query with field names in SELECT clause, it is not possible to map field to numeric indexes.

This is an example that i would imagine to be useful:

SELECT c.id AS 0, c.name AS 1, l.text AS 2 FROM Category c LEFT JOIN c.label l

Thus, the resulting results could be numeric indexed array. It is useful for many situations: when working with an API which expects such arrays, or when using list to assign result fields to variables directly.

Query::HYDRATE_SCALAR does not achieve this, as one could think at first glance.

@beberlei beberlei was assigned by doctrinebot
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.