提交 bd762ce8 authored 作者: noelgrandin's avatar noelgrandin

Improve error message when dropping an index that belongs to a constraint,…

Improve error message when dropping an index that belongs to a constraint, specify constraint in error message.
上级 6428e511
......@@ -20,6 +20,8 @@ Change Log
<h2>Next Version (unreleased)</h2>
<ul><li>Issue 73: MySQL compatibility: support REPLACE, patch by Cemo Koc.
</li><li>MVStore: concurrency problems have been fixed.
</li><li>Improve error message when dropping an index that belongs to a constraint,
specify constraint in error message.
</li></ul>
<h2>Version 1.3.174 (2013-10-19)</h2>
......
......@@ -60,7 +60,7 @@ public class DropIndex extends SchemaCommand {
if (Constraint.PRIMARY_KEY.equals(cons.getConstraintType())) {
pkConstraint = cons;
} else {
throw DbException.get(ErrorCode.INDEX_BELONGS_TO_CONSTRAINT_1, indexName);
throw DbException.get(ErrorCode.INDEX_BELONGS_TO_CONSTRAINT_1, indexName, cons.getName());
}
}
}
......
......@@ -1276,7 +1276,7 @@ public class ErrorCode {
* <pre>
* CREATE TABLE TEST(ID INT, CONSTRAINT UID UNIQUE(ID));
* DROP INDEX UID_INDEX_0;
* Index UID_INDEX_0 belongs to a constraint
* Index UID_INDEX_0 belongs to constraint UID
* </pre>
* Correct:
* <pre>
......
......@@ -104,7 +104,7 @@
90082=Sequenz {0} gehört zu einer Tabelle
90083=Feld wird referenziert durch {0}
90084=Kann das letzte Feld nicht löschen {0}
90085=Index {0} gehört zu einer Bedingung
90085=Index {0} gehört zu einer Bedingung {1}
90086=Klasse {0} nicht gefunden
90087=Methode {0} nicht gefunden
90088=Unbekannter Modus {0}
......
......@@ -104,7 +104,7 @@
90082=Sequence {0} belongs to a table
90083=Column may be referenced by {0}
90084=Cannot drop last column {0}
90085=Index {0} belongs to a constraint
90085=Index {0} belongs to constraint {1}
90086=Class {0} not found
90087=Method {0} not found
90088=Unknown mode {0}
......
......@@ -104,7 +104,7 @@
90082=Sequence {0} pertenece a una tabla
90083=La columna puede estar referenciada por {0}
90084=Imposible eliminar la ultima columna {0}
90085=Index {0} pertenece a un constraint
90085=Index {0} pertenece a un constraint {1}
90086=Class {0} no encontrada
90087=Method {0} no encontrado
90088=Modo desconocido {0}
......
......@@ -104,7 +104,7 @@
90082=Sekwencja {0} nalezy do tabeli
90083=Do kolumny mozna odwoloac sie przez referencje {0}
90084=Nie mozna skasowac ostatniej kolumny {0}
90085=Indeks {0} nalezy do ograniczenia
90085=Indeks {0} nalezy do ograniczenia {1}
90086=Klasa {0} nie istnieje
90087=Metoda {0} nie istnieje
90088=Nieznany stan {0}
......
......@@ -104,7 +104,7 @@
90082=Sequência {0} pertence a uma tabela
90083=A coluna pode ser referênciada por {0}
90084=Não pode apagar a última coluna {0}
90085=índice {0} pertence a uma restrição
90085=índice {0} pertence a uma restrição {1}
90086=Classe {0} não foi encontrada
90087=Método {0} não foi encontrado
90088=Modo {0} desconhecido
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论