Uploaded image for project: 'Doctrine 2 - ORM'
  1. Doctrine 2 - ORM
  2. DDC-86

Allow to generate index for an entity property

    Details

    • Type: New Feature
    • Status: Resolved
    • Priority: Major
    • Resolution: Invalid
    • Affects Version/s: 2.0-ALPHA2
    • Fix Version/s: None
    • Component/s: ORM
    • Security Level: All
    • Labels:
      None

      Description

      There is a unique option, but no index option for fields. This way you can't control the generation of indexes for fields which are used in queries often via the schema file and schema tool.

        Activity

        beberlei Benjamin Eberlei created issue -
        Hide
        romanb Roman S. Borschel added a comment - - edited

        There is @Table(...., indexes=

        {...}

        )

        I know you probably mean the "shortcut" in the @Column annotation. You think there should be shortcut for indexing, too? I think its far less common to index a normal field (non-pk, non-fk) than to make it unique. I will take a look whether there is an index option on the Column annotation in the JPA spec, just to see.

        Show
        romanb Roman S. Borschel added a comment - - edited There is @Table(...., indexes= {...} ) I know you probably mean the "shortcut" in the @Column annotation. You think there should be shortcut for indexing, too? I think its far less common to index a normal field (non-pk, non-fk) than to make it unique. I will take a look whether there is an index option on the Column annotation in the JPA spec, just to see.
        Hide
        beberlei Benjamin Eberlei added a comment - - edited

        indexes={} is enough I guess, haven't found it

        However i think indexes is not supported in SchemaTool

        Show
        beberlei Benjamin Eberlei added a comment - - edited indexes={} is enough I guess, haven't found it However i think indexes is not supported in SchemaTool
        beberlei Benjamin Eberlei made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Assignee Roman S. Borschel [ romanb ] Benjamin Eberlei [ beberlei ]
        Resolution Invalid [ 6 ]
        beberlei Benjamin Eberlei made changes -
        Workflow jira [ 10286 ] jira-feedback [ 14136 ]
        beberlei Benjamin Eberlei made changes -
        Workflow jira-feedback [ 14136 ] jira-feedback2 [ 16000 ]
        beberlei Benjamin Eberlei made changes -
        Workflow jira-feedback2 [ 16000 ] jira-feedback3 [ 18253 ]
        Hide
        ascarius Lionel Gaillard added a comment -

        By this way, mappedSuperclasses could finally add indexes...

        Show
        ascarius Lionel Gaillard added a comment - By this way, mappedSuperclasses could finally add indexes...

        This list may be incomplete, as errors occurred whilst retrieving source from linked applications:

        • Request to http://www.doctrine-project.org/fisheye/ failed: Error in remote call to 'FishEye 0 (http://www.doctrine-project.org/fisheye/)' (http://www.doctrine-project.org/fisheye) [AbstractRestCommand{path='/rest-service-fe/search-v1/crossRepositoryQuery', params={expand=changesets[0:20].revisions[0:29],reviews, query=DDC-86}, methodType=GET}] : Received status code 503 (Service Temporarily Unavailable)

          People

          • Assignee:
            beberlei Benjamin Eberlei
            Reporter:
            beberlei Benjamin Eberlei
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: