Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renaming index does not rename the index, but creates new one #2508

Closed
mishal opened this issue Sep 16, 2016 · 6 comments
Closed

Renaming index does not rename the index, but creates new one #2508

mishal opened this issue Sep 16, 2016 · 6 comments

Comments

@mishal
Copy link

mishal commented Sep 16, 2016

When I try to rename the index using the API, the old options are not passed to the new index, which causes that the index is not renamed, but different index is created.

$table = Table();
$table->addIndex(['name'], 'idx_name', [], [            
    'where' => 'name IS NOT NULL'
]);
$table->renameIndex('idx_name', 'idy_foo');

The method renameIndex() does not pass the options from the old index.

@deeky666
Copy link
Member

@mishal which platform are you using? Partial Indexes are currently only supported on PostgreSQL and SQLite.

@mishal
Copy link
Author

mishal commented Jan 19, 2017

PostgreSQL is platform of my choice :)

@mishal
Copy link
Author

mishal commented Jan 19, 2017

But this issue is not about partial indexes, the options array could contain anything else...

@deeky666
Copy link
Member

@mishal patch created: #2611

Ocramius added a commit that referenced this issue Jan 23, 2017
…g-indexes' into 2.5

Backport #2611 to 2.5
Backport #2508 to 2.5
@Ocramius
Copy link
Member

Handled via #2611

@github-actions
Copy link

github-actions bot commented Aug 6, 2022

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 6, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants