[DMIG-12] createIndexSql and dropIndexSql don't use the same logic to get the index name Created: 28/Oct/10  Updated: 16/Nov/10  Resolved: 16/Nov/10

Status: Resolved
Project: Doctrine Migrations
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major
Reporter: Lea Haensenberger Assignee: Jonathan H. Wage
Resolution: Won't Fix Votes: 0
Labels: None

Postgres 8.4


In the class Doctrine_Export the functions for creating and dropping indexes do not use the same logic to get the name of the index to be created or dropped.

When creating an index $this->conn->quoteIdentifier() is called on the index name.
When dropping an index $this->conn->quoteIdentifier($this->conn->formatter->getIndexName()) is called on the name, which by default adds '_idx' to the index name. Hence, when an index should be dropped in a migration an index with that name is not found because it was created without the '_idx'.

We use the migrations with a Postgres 8.4 database.

Comment by Lea Haensenberger [ 16/Nov/10 ]

I recreated the bug report in the doctrine 1 project since it rather belongs there.

Generated at Fri Oct 09 23:52:15 EDT 2015 using JIRA 6.4.10#64025-sha1:5b8b74079161cd76a20ab66dda52747ee6701bd6.