Doctrine 2 - ORM
  1. Doctrine 2 - ORM
  2. DDC-3014

[GH-973] Added index flags support in annotation, xml & yaml mapping drivers.

    Details

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

      Description

      This issue is created automatically through a Github pull request on behalf of adrianolek:

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

      Message:

      It allows specifying eg. fulltext index for MysqlPlatform (the platform already supports it - https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Platforms/MySqlPlatform.php#L714 , but it couldn't be used in annotations/xml/yaml/php schemas). And also other platforms use flags for indexes (virtual, clustered etc.).

      So now flags can be used like:

      ```php
      /**

      • @Table(...,indexes=
        Unknown macro: {@Index(columns={"description"},flags={"fulltext"})}

        )
        */
        class Foo

        { ... }

        ```

      ```xml
      ...
      <indexes>
      <index name="0" columns="description" flags="fulltext"/>
      </indexes>
      ...
      ```

      ```yml
      Foo:
      ...
      indexes:
      -
      columns: [ description ]
      flags: [ fulltext ]
      ```

      ```php
      $metadata->setPrimaryTable(array(
      ...
      'indexes' => array(
      array(
      'columns' => array('description'),
      'flags' => array('fulltext'),
      )
      ),
      ...
      ));
      ```

        Activity

        Hide
        Doctrine Bot added a comment -

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

        Show
        Doctrine Bot added a comment - A related Github Pull-Request [GH-973] was closed: https://github.com/doctrine/doctrine2/pull/973
        Show
        Marco Pivetta added a comment - Merged: https://github.com/doctrine/doctrine2/commit/3a1e24e6801961128c27104919050d40d745030b

          People

          • Assignee:
            Marco Pivetta
            Reporter:
            Doctrine Bot
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: