Fix wrong "DROP [index name]" clause when turning a normal key into a primary key. Fixes issue #2011.

This commit is contained in:
Ansgar Becker
2010-06-16 18:55:33 +00:00
parent d114097d48
commit e16d1bcc59
3 changed files with 6 additions and 2 deletions

View File

@ -2642,6 +2642,7 @@ begin
if Key.Name = '' then Key.Name := rx.Match[2]; // PRIMARY
Key.OldName := Key.Name;
Key.IndexType := rx.Match[2];
Key.OldIndexType := Key.IndexType;
Key.Algorithm := rx.Match[7];
if Key.IndexType = '' then Key.IndexType := 'KEY'; // KEY
Key.Columns := Explode(',', rx.Match[5]);