Mirajv1.0
EN

28. Error codes

Every error that MIRAJ returns carries three pieces of information: a numeric code, a 5-character SQLSTATE and a message in the server language. This page lists the numeric codes that the engine produces, with their SQLSTATE and the exact French wording of the message, together with an explanation of the typical cause and, where useful, a suggested fix.

1. How to read a MIRAJ error#

An error returned by the engine or by the network server looks like this:

ERROR 1146 (42S02): La table 'ventes.clients' n'existe pas

(This is how the miraj-cli console presents it in French; other clients write ERROR 1146 (42S02): ….)

  • 1146 is the numeric code, specific to MIRAJ (taken from a well-established historical numbering in the SQL ecosystem, so as to remain familiar to existing tools);
  • 42S02 is the SQLSTATE, an engine-independent standard (see §3);
  • the text is the message, produced from a template in which the %s placeholders have been replaced by the values of the error (table name, column name, etc.).

A warning (level Warning or Note) also carries a code from this page; the statement succeeds and SHOW WARNINGS lists it:

SELECT CAST('abc' AS SIGNED);
SHOW WARNINGS;
+-----------------------+
| CAST('abc' AS SIGNED) |
+-----------------------+
|                     0 |
+-----------------------+

+---------+------+------------------------------------------+
| Level   | Code | Message                                  |
+---------+------+------------------------------------------+
| Warning | 1292 | Truncated incorrect INTEGER value: 'abc' |
+---------+------+------------------------------------------+

2. Error code reference table#

The French message is given word for word (%s = value substituted at runtime: table name, column name, etc.).

2.1 Syntax and parsing errors#

CodeSQLSTATEMessageTypical causeSuggested fix
106442000Erreur de syntaxe SQL ; vérifiez le manuel de votre version de Miraj pour la syntaxe correcte près de '%s' à la ligne %sInvalid SQL construct, misplaced keyword, unsupported syntax, or query nesting depth exceeded (beyond 1,000 levels)Re-read the statement around the text quoted after "near"; check parentheses and commas
106542000La requête est videEmpty statement sent to the serverCheck that the client is not sending an empty string
762054001Instruction trop complexe : plus de %s éléments de syntaxe dans un même script (découpez-le en plusieurs instructions)Text sent in one block of more than 2 million syntax elements or 8 million tokens: INSERT … VALUES or IN list with several million values, large script sent all at once (chapter 16, §16.4.5)Split into several statements, or send the script statement by statement (miraj-cli connected to a server, miraj-dump restore)
113942000Erreur « %s » dans l'expression régulièreInvalid pattern passed to REGEXP, REGEXP_REPLACE, etc.Fix the pattern; the details of the regular expression engine's error are included in %s
1210HY000Arguments incorrects pour %sArgument(s) of a function or statement incompatible with its signatureCheck the number and type of the arguments
1221HY000Utilisation incorrecte de %s et %sCombination of two incompatible constructs in the same statementSeparate the two constructs or consult the documentation of the statement concerned
123542000Cette version de Miraj ne prend pas encore en charge '%s'Syntactically valid construct but not implemented in this versionUse an equivalent supported construct
130542000%s %s n'existe pasCall to an unknown function (FUNCTION f n'existe pas); ROLLUP and CUBE are not functions: they can only be written in a GROUP BYFix the name; check the list in chapters 10 and 7
158242000Nombre de paramètres incorrect dans l'appel de la fonction native '%s'Number of arguments outside the function's arity (GROUPING() with no argument, COLUMN_GET with two arguments...)Check the signature in chapter 10
4009HY000La spécification de fenêtre nommée '%s' n'est pas définieOVER w or OVER (w ...) with no window w in the WINDOW clause of the same block, or defined after the one that refers to itDefine the window in the WINDOW clause of the block, before referring to it (chapter 9, §9.18)
4010HY000Plusieurs spécifications de fenêtre portent le même nom '%s'Two windows with the same name in a WINDOW clause (case is ignored)Give each window a distinct name
4011HY000Une spécification de fenêtre qui en reprend une autre ('%s') ne peut pas contenir de liste de partitionOVER (w PARTITION BY ...)Write the PARTITION BY in the named window
4012HY000La spécification de fenêtre reprise '%s' contient déjà une liste de triOVER (w ORDER BY ...) while w already has an ORDER BYRemove one of the two ORDER BY
4013HY000La spécification de fenêtre reprise '%s' ne peut pas contenir de cadreOVER (w ...) while w has a ROWS or RANGE frameWrite OVER w, or put the frame in the window that refers to w
4019HY000Un cadre de type RANGE demande une clause ORDER BY à une seule clé de triRANGE frame with an offset (n PRECEDING, INTERVAL n unit FOLLOWING...) in a window with no ORDER BY or with several sort keysSort the window on a single key, or use ROWS
4021HY000Un cadre de type RANGE demande un type numériqueNumeric offset of a RANGE frame on a sort key that is not numericOn a date, write INTERVAL n unit PRECEDING; otherwise sort on a numeric key
4099HY000Le constructeur de table utilisé a un nombre de valeurs différent d'une ligne à l'autreVALUES (1, 2), (3) used as a query: the rows do not all have the same number of valuesGive every row the same number of values
4100HY000La référence de colonne '%s' ne peut pas être utilisée dans un constructeur de tableColumn cited in a row of a VALUES (...) used as a query, even a column of an enclosing queryWrite a subquery in the row, or a SELECT instead of the VALUES
4180HY000FETCH ... WITH TIES exige la présence d'une clause ORDER BYFETCH FIRST n ROWS WITH TIES in a block with no ORDER BY: ties are only defined by a sort orderAdd the ORDER BY, or write ONLY
1111HY000Utilisation invalide d'une fonction d'agrégationAggregate, or GROUPING(), in a WHERE or without GROUP BYMove the condition to HAVING; GROUPING() is only used with GROUP BY (§9.17)
122221000Les SELECT utilisés n'ont pas le même nombre de colonnesMembers of a UNION, INTERSECT or EXCEPT that do not have the same number of columns (SELECT 1 UNION SELECT 1, 2)Give every member the same column list
124121000L'opérande doit contenir %s colonne(s)Row constructor compared with a value or a subquery of a different width ((1,2) = 1, (id, nom) = (SELECT id …))Compare lists of the same width
117642000La clé '%s' n'existe pas dans la table '%s'USE INDEX, FORCE INDEX or IGNORE INDEX naming an index unknown to the tableCheck the name with SHOW INDEX FROM table
1191HY000Aucun index FULLTEXT ne correspond à la liste de colonnesMATCH (…) AGAINST (…) on columns that no FULLTEXT index coversCreate the FULLTEXT index on exactly those columns
1243HY000Identifiant de requête préparée inconnu (%s) donné à %sEXECUTE or DEALLOCATE PREPARE of a name that was not prepared in the sessionPREPARE name FROM '…' first
3636HY000Requête récursive interrompue après %s itérations. Augmentez @@cte_max_recursion_depthRecursive table expression (WITH RECURSIVE) with no stop condition, or deeper than cte_max_recursion_depth (1000 by default)Add the stop condition, or raise cte_max_recursion_depth
3580HY000L'argument n°%s de la fonction GROUPING ne figure pas dans GROUP BYGROUPING(p) where p is not an expression of the GROUP BYPass to GROUPING the GROUP BY expressions as written
4177HY000Toute fonction table doit avoir un alias.FROM JSON_TABLE(...) without an aliasAdd [AS] alias
3668HY000Les références latérales de '%s' exigent une jointure INNER ou LEFTJSON_TABLE whose document cites a table placed earlier, joined by RIGHT JOINUse the comma, JOIN or LEFT JOIN
111542000Jeu de caractères inconnu : '%s'Unknown character set in SET NAMES, SET CHARACTER SET or SET character_set_client / _results / _connection / _server / _database (SET NAMES klingon)utf8mb4 (or a recognized set, or DEFAULT)
125342000La collation '%s' n'est pas valide pour le jeu de caractères '%s'Collation of another character set (CHARACTER SET latin1 COLLATE utf8mb4_unicode_ci, 'a' COLLATE utf8_bin on a utf8mb4 text: La collation 'utf8mb3_bin' n'est pas valide pour le jeu de caractères 'utf8mb4')Use a utf8mb4_… collation (see the Collations chapter)
1267, 1270, 1271HY000Mélange illégal de collationsNever raised by Miraj: a mix with no winner is compared under the widest collation (chapter Collations, § 13.3)—
1273HY000Collation inconnue : '%s'Unsupported collation name (utf8mb4_0900_ai_ci, *_as_cs, linguistic) in a column definition, a table definition or an expression; in SET NAMES … COLLATE and SET collation_connection, collation_server or collation_database, only a name that belongs to no recognized set (klingon_ci) is refused, the others being accepted under the general collation (warning 1273 for SET collation_connection)utf8mb4_general_ci, utf8mb4_unicode_ci or utf8mb4_bin
1302HY000Déclarations contradictoires : '%s' et '%s'Column declared BINARY with a non-binary COLLATEKeep one of the two
140742000SQLSTATE incorrect : '%s'SIGNAL/RESIGNAL SQLSTATE '...' in a routine with a value that is not a valid 5-character codeUse a compliant SQLSTATE (5 characters, class other than 00, 01, XA)

2.2 Schema errors (databases, tables, columns, indexes)#

CodeSQLSTATEMessageTypical causeSuggested fix
29HY000Fichier '%s' introuvable (code : %s)File expected by the engine missing from disk (table, journal...)Check the path and access rights on the data folder
1004HY000Impossible de créer le fichier '%s' (errno : %s)Disk write impossible (permissions, disk full, invalid path)Check disk space and permissions on the data folder
1007HY000Impossible de créer la base '%s' ; elle existe déjàCREATE DATABASE without IF NOT EXISTS on an existing databaseAdd IF NOT EXISTS or choose another name
1008HY000Impossible de supprimer la base '%s' ; elle n'existe pasDROP DATABASE without IF EXISTS on a missing databaseAdd IF EXISTS or check the name
104442000Accès refusé pour l'utilisateur '%s'@'%s' à la base de données '%s'Account without privilege on the database (checked at each USE and at the handshake)Grant a database privilege with GRANT
104528000Accès refusé pour l'utilisateur '%s'@'%s' (mot de passe utilisé : %s)Invalid credentials at connectionCheck the account and password
10463D000Aucune base de données sélectionnéeStatement requiring a current database executed without USERun USE <database> before the statement, or qualify the objects
104942000Base de données '%s' inconnueUSE or reference to a database that does not existCheck the spelling or create the database
105042S01La table '%s' existe déjàCREATE TABLE without IF NOT EXISTS on a name already taken (table or view)Add IF NOT EXISTS, or DROP / CREATE OR REPLACE
105142S02Table '%s' inconnueDROP TABLE of a missing table, without IF EXISTS (Table 'ventes.nope' inconnue)Check the name and the current database
105223000La colonne '%s' dans %s est ambiguëColumn present in several tables of the query without qualificationQualify the column (table.column)
105442S22Colonne '%s' inconnue dans '%s'Misspelled column name or column that does not exist in the given contextCheck DESCRIBE <table> or information_schema.COLUMNS
106042S21Nom de colonne '%s' en doubleTwo columns with the same name in one table definition or a CREATE TABLE … SELECTRename one of the columns or give it an alias
106142000Nom de clé '%s' en doubleTwo indexes/keys with the same name on the tableChoose another index name
106642000Table ou alias non unique : '%s'Same table name or alias used twice in a queryGive each occurrence a distinct alias
110242000Nom de base de données incorrect : '%s'Name outside the rules (length, allowed characters)Use ASCII characters, digits, _, $ and space (never in last position), 64 bytes at most
110342000Nom de table incorrect : '%s'Same rule as 1102, applied to the table nameSame
110942S02Table '%s' inconnue dans %sReferenced table missing in the specified context (%s: clause, join...)Check the table name in that clause
114642S02La table '%s.%s' n'existe pasTable missing from the indicated databaseCheck the name and the database, or create it
116642000Nom de colonne incorrect : '%s'Column name outside the identifier rulesRename according to the rules
117042000La colonne BLOB/TEXT '%s' est utilisée dans une clé sans longueur de cléWhole BLOB column or geometry column (POINT…) in a primary key, geometry column in an ordinary indexUse a bounded-length column, a UNIQUE key (which accepts a whole BLOB), or a SPATIAL index for a geometry
128042000Nom d'index incorrect : '%s'Invalid or too long index nameShorten or fix the name
1031HY000Le moteur de stockage %s de la table %s n'a pas cette optionFeature not supported by a disk table (ENGINE = Aria, MyISAM, DISK): vector index, partitioning, replication on a secondaryKeep the table in memory (ENGINE = InnoDB or no ENGINE clause)
1214HY000Le type de table utilisé ne prend pas en charge les index FULLTEXTFULLTEXT or trigram index on a disk table (including a dump using ENGINE=MyISAM with a FULLTEXT index)Remove the ENGINE clause or replace it with ENGINE = InnoDB
1266HY000Moteur de stockage %s utilisé pour la table '%s'Warning: ENGINE = Aria / MyISAM / DISK on a temporary table, which stays in memoryNo action: the temporary table is created in memory
128642000Moteur de stockage '%s' inconnuSET default_storage_engine with an unknown engine nameUse MIRAJ, InnoDB, MEMORY, Aria, MyISAM or DISK
3162HY000Le compte %s n'existe pas.Warning from DROP USER IF EXISTS, ALTER USER IF EXISTS or DROP ROLE IF EXISTS on a missing account or role (the warning text is Authorization ID 'zz'@'%' does not exist.)None: the account is skipped, the others are processed
3163HY000Le compte %s existe déjà.Warning from CREATE USER IF NOT EXISTS or CREATE ROLE IF NOT EXISTS on an existing account or roleNone; without IF NOT EXISTS, the error is 1396 (§2.4)
106342000Spécification de colonne incorrecte pour la colonne '%s'Attribute incompatible with the column type, for example PERIOD FOR columns that are not dates (chapter 12)Fix the type or the attribute
106742000Valeur par défaut invalide pour '%s'DEFAULT that cannot be converted to the column type (a INT DEFAULT 'abc')Give a default value of the right type
107242000La colonne de clé '%s' n'existe pas dans la tableIndex or key that names a column missing from the table (KEY (b))Fix the column name
107542000Définition de table incorrecte ; il ne peut y avoir qu'une seule colonne auto-incrémentée et elle doit être une cléTwo AUTO_INCREMENT columns, or an AUTO_INCREMENT column that is not the first column of any indexKeep a single AUTO_INCREMENT column and index it (PRIMARY KEY)
109142000Impossible de supprimer %s %s ; vérifiez qu'il existeALTER TABLE … DROP COLUMN, DROP INDEX, DROP CONSTRAINT or DROP INDEX … ON t of a missing elementCheck the name; with IF EXISTS, a simple note 1091
111042000Colonne '%s' indiquée deux foisSame column used for the start and the end of a PERIOD FORGive two distinct columns
1505HY000Gestion de partitions impossible sur une table non partitionnéeALTER TABLE … DROP / TRUNCATE / … PARTITION on a table that is not partitionedCheck the target table
1526HY000Aucune partition de la table ne reçoit la valeur %sRow of a PARTITION BY RANGE or LIST table that no partition coversAdd a partition (VALUES LESS THAN MAXVALUE, DEFAULT)
1826HY000Nom de contrainte %s en double '%s'Two constraints with the same name in a table (CONSTRAINT k CHECK … twice)Rename one of the constraints
1829HY000Impossible de supprimer la colonne '%s' : elle est nécessaire à la contrainte de clé étrangère '%s' de la table '%s'ALTER TABLE parent DROP COLUMN of a column referenced by a foreign key of another tableDrop the foreign key of the child table first
3730HY000Impossible de supprimer la table '%s' référencée par la contrainte de clé étrangère '%s' de la table '%s'.DROP TABLE of a parent table that is still referencedDrop the child table or its foreign key first (or SET foreign_key_checks = 0)
3821HY000La contrainte de vérification '%s' est introuvable dans la table.ALTER TABLE … DROP CHECK of a missing constraintCheck the name in SHOW CREATE TABLE
409242S02VIEW inconnue : '%s'DROP VIEW of a missing view, without IF EXISTSDROP VIEW IF EXISTS

2.3 Constraint and data errors#

CodeSQLSTATEMessageTypical causeSuggested fix
104823000La colonne '%s' ne peut pas être NULLINSERT/UPDATE supplying NULL to a NOT NULL column with no implicit value availableProvide a value, or reconsider the NOT NULL constraint
106223000Doublon '%s' pour la clé '%s'Violation of a primary key or UNIQUE constraintUse INSERT IGNORE, REPLACE or ON DUPLICATE KEY UPDATE if the duplicate is expected
106842000Plusieurs clés primaires définiesTwo PRIMARY KEY clauses in the same table definitionKeep only one
1093HY000La table '%s' est indiquée deux fois, comme cible de '%s' et comme source séparée de donnéesSubquery of the RETURNING clause of an INSERT, REPLACE or DELETE that reads the table being written (§8.9)Read the table with a separate statement, after the write
113621S01Le nombre de colonnes ne correspond pas au nombre de valeurs à la ligne %sINSERT ... VALUES (...) with a number of values different from the number of columnsMake the two lists match
113822004Utilisation incorrecte de la valeur NULLNULL used where it is not allowed (e.g. value of a constraint)Remove the NULL or reconsider the expression
117242000Le résultat compte plus d'une ligneScalar subquery or SELECT ... INTO receiving several rowsAdd a condition that reduces the result to one row, or use LIMIT 1 knowingly
1215HY000Impossible d'ajouter la contrainte de clé étrangèreInvalid foreign key definition (incompatible types, missing index on the parent side...)Check the column types and the existence of an index on the referenced column
124221000La sous-requête renvoie plus d'une ligneSubquery used in a scalar context (=, SELECT ... INTO) that returns several rowsRestrict the subquery or use IN / EXISTS
126422003Valeur hors limites pour la colonne '%s' à la ligne %sNumeric value outside the range of the declared typeUse a wider type or fix the value
129222007Valeur %s incorrecte tronquée : '%s'Failed conversion with truncation (e.g. non-numeric string converted to a number); also Incorrect vector value: bytes or text that do not form a vector of the VECTOR(n) column (chapter 6)Fix the source value or its format
4078HY000Cannot cast '%s' as 'vector' in assignment of %sNumber or date assigned to a VECTOR(n) column (INSERT … VALUES (1, 12), UPDATE … SET v = 12), refused at preparation, even if no row is written; warning outside strict modeWrite the vector as text '[…]', with VEC_FromText, or as bytes
136522012Division par zéroDivision or modulo by 0 in a write (INSERT, UPDATE) when sql_mode contains ERROR_FOR_DIVISION_BY_ZERO and a strict mode; with ERROR_FOR_DIVISION_BY_ZERO alone, or in a SELECT, warning and NULL result; without this mode, NULL with no warningGuard the expression (CASE WHEN ... != 0) or accept the NULL result depending on the SQL mode
136622007Valeur %s incorrecte : '%s' pour la colonne %s à la ligne %sValue incompatible with the column type on write, in strict mode ('z' in an INT column)Fix the value or the column type
140622001Données trop longues pour la colonne '%s' à la ligne %sString longer than the declared column lengthEnlarge the column or truncate the value upstream
145123000Impossible de supprimer ou de modifier une ligne parente : une contrainte de clé étrangère échoue (%s)Deletion/modification of a row still referenced by a child tableDelete/modify the child rows first, or reconsider the ON DELETE/ON UPDATE action
145223000Impossible d'ajouter ou de modifier une ligne enfant : une contrainte de clé étrangère échoue (%s)Insertion/modification referencing a nonexistent parent rowInsert the parent row first, or check the foreign key value
4082HY000La variable de ligne '%s' n'a pas de champ '%s'row.column field missing from the row of a FOR row IN … loopFix the name, or give the column an alias in the loop query
4084HY000La séquence '%s.%s' est épuiséeNEXTVAL beyond MAXVALUE (or MINVALUE) of a sequence without CYCLEALTER SEQUENCE … RESTART, widen the bounds or add CYCLE
4085HY000La séquence '%s.%s' a une valeur hors limites pour ses optionsMINVALUE ≥ MAXVALUE, START outside the bounds, negative CACHE...Fix the options
408942S02'%s.%s' n'est pas une SEQUENCESHOW CREATE SEQUENCE, ALTER SEQUENCE, NEXTVAL / LASTVAL / SETVAL or DEFAULT NEXTVAL(…) on a table or a view, checked when the statement is opened even if they are never evaluatedTarget a sequence
409042S02'%s.%s' n'est pas une SEQUENCEDROP SEQUENCE of a table (note with IF EXISTS)DROP TABLE
196542S02'%s.%s' est une vueDROP SEQUENCE of a view (note with IF EXISTS)DROP VIEW
409142S02SEQUENCE inconnue : '%s'DROP SEQUENCE or ALTER SEQUENCE of a missing sequence (note with IF EXISTS); call of an unknown sequence that comes before any table of the statement (SELECT NEXTVAL(s)) — after a table, or in a function or a trigger: 1146DROP SEQUENCE IF EXISTS, check the name
4093HY000INSERT incorrect dans une SEQUENCE. Seul un INSERT sur une seule table est possible dans un objet séquence (…). Pour modifier la SEQUENCE, utilisez ALTER SEQUENCE.INSERT, UPDATE or DELETE targeting a sequenceALTER SEQUENCE or SETVAL
1256HY000Taille des données décompressées trop grande ; la taille maximale est %s (la longueur des données décompressées est probablement corrompue)Warning from UNCOMPRESS (NULL result): the length announced by the header exceeds max_allowed_packetCheck that the value really comes from COMPRESS and was not truncated or converted to text
1258HY000ZLIB : pas assez de place dans le tampon de sortie (la longueur des données décompressées est probablement corrompue)Warning from UNCOMPRESS (NULL result): the stream returns more bytes than the announced lengthSame
1259HY000ZLIB : données d'entrée corrompuesWarning from UNCOMPRESS or UNCOMPRESSED_LENGTH (NULL result): value of four bytes or fewer, corrupted or truncated zlib streamSame; store compressed values in a VARBINARY or BLOB column
1300HY000Chaîne de caractères %s invalide : '%s'Warning from CHR(code) (NULL result): the bytes of code do not form a character of the setGive the character code in its encoding (CHR(50089) for é), or use CHAR(code)
1298HY000Fuseau horaire inconnu ou incorrect : '%s'SET time_zone or SET GLOBAL time_zone with a name absent from the IANA database, or an offset outside -13:59 to +14:00; CONVERT_TZ returns NULL in this case, without an errorWrite SYSTEM, a ±HH:MM offset or an IANA name (Europe/Paris)
4176HY000Impossible de donner une valeur à la colonne '%s' de JSON_TABLE '%s'.JSON_TABLE column declared ERROR ON EMPTY whose path designates nothingWrite NULL ON EMPTY or DEFAULT '...' ON EMPTY
4178HY000Impossible de placer un tableau ou un objet dans la colonne scalaire '%s' de JSON_TABLE '%s'.Scalar JSON_TABLE ... ERROR ON ERROR column whose path designates an array or an objectTarget a scalar value, or declare the column JSON
4179HY000Impossible de placer plusieurs valeurs désignées par le chemin dans la colonne '%s' de JSON_TABLE '%s'.JSON_TABLE ... ERROR ON ERROR column whose path (wildcard, range) designates several valuesDesignate a single value, or use NESTED PATH
4146HY000%s doit être de type %s pour la table versionnée %sPeriod column of a WITH SYSTEM VERSIONING table that is neither TIMESTAMP nor DATETIME (chapter 12)Fix the type
4119HY000Interdit sur la table versionnée %s.%s. Changez @@system_versioning_alter_history pour poursuivre l'ALTER.ALTER TABLE that changes the columns of a versioned tableSET system_versioning_alter_history = KEEP
4124HY000La table %s n'est pas versionnée par le systèmeFOR SYSTEM_TIME, DELETE HISTORY, PARTITION BY SYSTEM_TIME or DROP SYSTEM VERSIONING on an ordinary tableALTER TABLE ... ADD SYSTEM VERSIONING
4127HY000Paramètres invalides pour la table partitionnée %s : valeur incorrecte pour '%s'INTERVAL / LIMIT of zero, STARTS that is not a point in timeFix the PARTITION BY SYSTEM_TIME clause
4128HY000Partitions incorrectes pour %s : au moins une partition HISTORY et exactement une dernière partition CURRENT sont requisesNo HISTORY partition, CURRENT missing, duplicated or not last; removal of CURRENT or of the last HISTORYKeep at least one HISTORY and one CURRENT last
4131HY000Impossible de faire DROP SYSTEM VERSIONING sur la table %s partitionnée BY SYSTEM_TIMEDROP SYSTEM VERSIONINGALTER TABLE ... REMOVE PARTITIONING first
4135HY000La table %s est déjà versionnée par le systèmeADD SYSTEM VERSIONING on a table that is already versionedNothing to do
4152 à 4158HY000Application periodstemporary table, different types, two periods, generated or system column, unknown period, period column in SET, DROP CONSTRAINT of the periodSee chapter 12, §12.6 and §12.7
4170, 4171HY000WITHOUT OVERLAPS keyperiod column named in the key, non-unique indexSee chapter 12, §12.8
4037 / 4038HY000Fin inattendue du texte JSON dans l'argument %s de la fonction '%s' / Erreur de syntaxe dans le texte JSON de l'argument %s de la fonction '%s' à la position %sDocument passed to a JSON function that is not valid JSON: warning and NULL result (error for JSON_TABLE)Fix the document; JSON_VALID makes it possible to skip invalid rows
4041 / 4042HY000Fin inattendue du chemin JSON dans l'argument %s de la fonction '%s' / Erreur de syntaxe dans le chemin JSON de l'argument %s de la fonction '%s' à la position %sBadly written JSON path ('$.', 'a', '$[1'...): warning and NULL result (error for JSON_TABLE)Start with $ and follow the path syntax (chapter 9.10)
4036HY000Caractère interdit en JSON dans l'argument %s de la fonction '%s' à la position %sUnescaped control character (tab, line feed...) in a string of a document: warning and NULL result (error for JSON_TABLE)Escape the character (\t, \n)
4044HY000Jokers et plages interdits dans le chemin JSON de l'argument %s de la fonction '%s'Wildcard or range in the path of a modification function, JSON_KEYS, JSON_LENGTH or JSON_CONTAINS: warning and NULL resultDesignate a single value
4051HY000Le chemin '$' est interdit dans l'argument %s de la fonction '%s'.JSON_REMOVE(doc, '$'): warning and NULL resultDesignate a member or an element
4193HY000Valeur invalide pour le mot-clé %sJSON_SCHEMA_VALID whose schema gives type an unknown value (integer included)Write number, string, object, array, boolean or null
4046HY000L'argument %s de la fonction '%s' doit valoir "one" ou "all".Mode of JSON_CONTAINS_PATH / JSON_SEARCH badly written: warning and NULL resultWrite 'one' or 'all'
315622018Valeur JSON invalide pour une conversion en %s depuis la colonne %s à la ligne %sJSON_VALUE ... ERROR ON ERROR on a value that cannot be converted or is not scalarReview the RETURNING type, or choose NULL / DEFAULT ON ERROR
315722032Le document JSON dépasse la profondeur maximale.More than 100 nesting levelsFlatten the document
315822032Un document JSON ne peut pas avoir de membre dont le nom est NULL.NULL key in JSON_OBJECT or JSON_OBJECTAGGSkip the rows whose key is NULL
316542000Le chemin ne désigne pas une case de tableau.Path of JSON_ARRAY_INSERT that does not end with [n]End the path with an array element
396622035Aucune valeur trouvée par '%s' au chemin indiqué.JSON_VALUE ... ERROR ON EMPTY on a path that designates nothingChoose NULL / DEFAULT ON EMPTY, or check the path
402523000La CONTRAINTE %s a échoué pour %s.%sRow rejected by a CHECK constraintFix the value to satisfy the constraint, or reconsider the constraint
1364HY000Le champ '%s' n'a pas de valeur par défautINSERT that gives no value to a NOT NULL column without DEFAULT, in strict modeProvide the value, or give the column a DEFAULT
136944000Échec de CHECK OPTION %s.%sINSERT or UPDATE through a WITH CHECK OPTION view of a row that the view would not showWrite a row that satisfies the WHERE of the view
169022003La valeur %s est hors limites dans '%s'Integer computation that exceeds its type (9223372036854775807 + 1: La valeur BIGINT est hors limites dans '9223372036854775807 + 1')Convert to DECIMAL before the computation, or reduce the values
170142000Impossible de vider une table référencée par une contrainte de clé étrangère (%s)TRUNCATE TABLE of a parent tableDELETE FROM, or drop the foreign key first
126501000Données tronquées pour la colonne '%s' à la ligne %sWarning outside strict mode: string that is too long shortened, value adjusted to the column (in strict mode: 1406 or 1366)Check the data; SHOW WARNINGS gives the column and the row
144122008Fonction de date : dépassement du champ %sWarning from a date computation outside the allowed range (DATE_ADD('9999-12-31', INTERVAL 1 DAY)): NULL resultCheck the bounds of the computation

2.4 Privilege errors#

CodeSQLSTATEMessageTypical causeSuggested fix
104442000Accès refusé pour l'utilisateur '%s'@'%s' à la base de données '%s'Account without privilege on the database (checked at each USE and at the handshake)Grant a database privilege with GRANT
114242000Commande %s refusée à l'utilisateur '%s'@'%s' pour la table %s.%sTable-level check, even before name resolutionGrant the required table privilege (SELECT, INSERT...)
114342000Commande %s refusée à l'utilisateur '%s'@'%s' pour la colonne '%s' de la table '%s'The account has the privilege only on some columns of the table, not on the one the statement reads or writes (chapter 15, column privileges)Grant the privilege on the column (GRANT SELECT (col) ON database.table) or on the table
114442000Commande GRANT/REVOKE invalide ; consultez le manuel pour savoir quels privilèges s'appliquent à ce niveauGRANT/REVOKE of a privilege at a level where it makes no sense (e.g. table privilege at the global level)Use the level appropriate to the privilege
114142000Aucun droit de ce type n'est défini pour l'utilisateur '%s' sur l'hôte '%s'Global-level REVOKE of a privilege the account does not haveCheck SHOW GRANTS FOR account
1396HY000L'opération %s a échoué pour %sCREATE USER or CREATE ROLE of an account that already exists, DROP USER, DROP ROLE or ALTER USER of a missing account; no account of the list is processedIF NOT EXISTS / IF EXISTS (warnings 3163 / 3162)
141042000Vous n'êtes pas autorisé à créer un compte avec GRANTGRANT … TO an account that does not existCREATE USER first
3118HY000Accès refusé pour l'utilisateur '%s'@'%s'. Le compte est verrouillé.Connection to an ACCOUNT LOCK accountALTER USER … ACCOUNT UNLOCK
104008004Trop de connexionsmax_connections connections already open: error packet sent in place of the handshakeClose unneeded connections or raise --max-connections / SET GLOBAL max_connections
1129HY000L'hôte '%s' est bloqué après de trop nombreux échecs de connexion ; débloquez-le par 'FLUSH HOSTS'max_connect_errors consecutive authentication failures from this address (15-minute block)Fix the password of the faulty client, then FLUSH HOSTS from an open connection
104308S01le client exige TLS ; le serveur n'a pas de certificat, voir --tls-certClient set to require encryption (driver in mandatory SSL mode) facing a server started without a certificate; the connection is then closed and the server journal carries the same messageProvide a certificate to the server (--tls-cert, --tls-key, chapter 16), or connect without requiring TLS
315908004Les connexions non chiffrées sont refusées : le serveur exige TLS (--require-tls).Unencrypted client facing a server with a certificate (TLS required as soon as a certificate is provided, except with --allow-plain-with-tls)Enable TLS in the client
1135HY000Impossible de créer un nouveau fil pour la connexion (%s)The system refuses one more thread (memory, process limit)Reduce max_connections or the load on the machine
122742000Accès refusé ; il faut le privilège %s pour cette opérationGlobal-level check (SUPER, RELOAD, SHUTDOWN...)Grant the global privilege named in the message
137042000Commande %s refusée à l'utilisateur '%s'@'%s' pour la routine '%s'Call of a procedure or a function without EXECUTE on it, on its database or at global level; GRANT on a routine without the GRANT option on itGRANT EXECUTE ON PROCEDURE database.name TO … (or ON database.*)
140342000Aucun droit de ce type n'est défini pour l'utilisateur '%s' sur l'hôte '%s' pour la routine '%s'REVOKE … ON PROCEDURE | FUNCTION database.name of a privilege the account does not have on this routineCheck SHOW GRANTS FOR account; REVOKE IF EXISTS
1524HY000Le greffon '%s' n'est pas chargéIDENTIFIED WITH (or VIA) a plugin other than the native plugin (caching_sha2_password, auth_socket…)Use IDENTIFIED BY 'password' or IDENTIFIED WITH miraj_password BY ...
3523HY000Compte ou rôle inconnu %s@%sSET ROLE or GRANT/REVOKE on a role that does not existCreate the role with CREATE ROLE or fix the name
3530HY000%s@%s n'est pas accordé à %s@%sSET ROLE on a role not granted to the current accountGrant the role with GRANT <role> TO <account>
3619HY000Niveau de privilège invalide pour %sDynamic privilege requested outside the global levelGrant at the global level (ON *.*)

2.5 Transaction and concurrency errors#

CodeSQLSTATEMessageTypical causeSuggested fix
1205HY000Délai d'attente du verrou dépassé ; réessayez la transactionLOCK TABLES, SELECT ... FOR UPDATE NOWAIT/WAIT n, global read lock of another session (FLUSH TABLES WITH READ LOCK), or waiting for a table lock beyond lock_wait_timeoutRetry the transaction; consider shortening the duration of concurrent transactions
121340001Interblocage détecté lors de la prise du verrou ; réessayez la transactionConcurrency between transactions on the same rows (Miraj never waits: this code covers both a real deadlock and a simple MV-OCC version conflict after 3 internal attempts). Also returned by a COMMIT whose deferred update can no longer be applied (row deleted, WHERE condition that has become false, row held by another transaction, row read then modified by another transaction)Retry the transaction on the client side; since Miraj has no blocking wait, this code appears more often than on a classic lock-based engine. A COMMIT may also return the code of a computation error discovered while recomputing a deferred update (1264, 1048, 4025…): the transaction is then rolled back entirely (chapter 14, §14.2)
1397XAE04XAER_NOTA : XID inconnuXA END / XA PREPARE with an XID other than that of the session's branch; XA COMMIT / XA ROLLBACK of an unknown XID or one held by another, still open sessionCheck the XID; a branch is taken over by another session only once prepared and its session closed
1398XAE05XAER_INVAL : arguments invalides (ou commande non prise en charge)XA START '', XA START … JOIN, XA END … SUSPEND, XA COMMIT … ONE PHASE of a prepared branchUse a non-empty gtrid; commit a prepared branch without ONE PHASE
1399XAE07XAER_RMFAIL : la commande ne peut pas être exécutée quand la transaction globale est dans l'état %sStatement forbidden in the branch's state (chapter 14, §14.5): COMMIT or DDL in ACTIVE, reading a table in IDLE or PREPARED, XA PREPARE outside IDLEFollow the sequence XA START → XA END → XA PREPARE → XA COMMIT
1400XAE09XAER_OUTSIDE : du travail est fait hors de la transaction globaleXA START with an ordinary transaction open (or autocommit = 0 after a statement) or under LOCK TABLES; XA COMMIT / XA ROLLBACK of another branch in these conditionsCommit or roll back the open transaction, UNLOCK TABLES, or SET autocommit = 1
1402XA100XA_RBROLLBACK : la branche de transaction a été annuléeTakeover of a prepared branch that had written nothing: it was closed with its sessionNo action: the branch had no effect
1440XAE08XAER_DUPID : le XID existe déjàXA START of an XID held by another branch (still open, or prepared and detached)Choose another XID, or resolve the existing branch (XA RECOVER)
1614XA102XA_RBDEADLOCK : la branche de transaction a été annulée : un interblocage a été détectéXA PREPARE whose read proof fails; branch whose transaction was rolled back by a conflict (XA END, XA COMMIT, statement on a table)XA ROLLBACK if the branch still exists, then replay the transaction
1791HY000Nom de format de XA RECOVER inconnu : '%s'XA RECOVER FORMAT = '…' other than RAW or SQLUse RAW (default) or SQL
179225006Impossible d'exécuter l'instruction dans une transaction en lecture seule (READ ONLY).Write attempted in a transaction opened as READ ONLY, or on a cluster secondary (see §2.6)Open a read-write transaction, or write to the primary node
156825001%s ne peut pas être fixé pendant une transaction en coursSET TRANSACTION ISOLATION LEVEL …, SET TRANSACTION READ ONLY or SET @@transaction_read_only (without scope) in an open transactionPut it before START TRANSACTION, or write SET SESSION …
192770100La connexion a été arrêtéeConnection terminated by KILL or by the serverReconnect
196970100Requête interrompue : limite de durée de %s s dépasséemax_statement_time or the MAX_EXECUTION_TIME hint exceededOptimize the query or raise the limit if it is legitimate
1095HY000Vous n'êtes pas propriétaire de la connexion %sKILL of a connection that does not belong to the current account, without the required privilegeUse an account with the appropriate privilege, or target your own connection
1094HY000Identifiant de connexion inconnu : %sKILL with a connection identifier that no longer existsCheck the identifier with SHOW PROCESSLIST
1099HY000La table '%s' est verrouillée en lecture (READ) et ne peut pas être modifiéeWrite attempted on a table read-locked by LOCK TABLESLock for writing (WRITE) or wait for the lock to end
1192HY000Impossible d'exécuter cette commande : la session tient des tables verrouillées ou une transaction activeFLUSH TABLES WITH READ LOCK (or FLUSH TABLES t … WITH READ LOCK | FOR EXPORT) under LOCK TABLESUNLOCK TABLES first
1223HY000Impossible d'exécuter la requête : la session tient un verrou de lecture incompatibleWrite (DML, DDL, accounts, LOCK TABLES … WRITE, RESTORE) by the session holding the global read lock (FLUSH TABLES WITH READ LOCK)UNLOCK TABLES, then write
1100HY000La table '%s' n'a pas été verrouillée par LOCK TABLESTable used in a session under LOCK TABLES without itself having been lockedAdd the table to the LOCK TABLES list

2.6 Cluster and replication errors (Cluster edition)#

CodeSQLSTATEMessageTypical causeSuggested fix
1290HY000Le serveur fonctionne avec l'option %s et ne peut pas exécuter cette instructionAttempted write on a read-only secondary node, or server option incompatible with the statementWrite to the cluster's primary node; consult SHOW CLUSTER STATUS
9002HY000%s demande l'édition Miraj ClusterEffective partitioning feature (segments, EXCHANGE PARTITION on HASH/KEY...) used outside the Cluster editionSwitch to the Cluster edition, or limit yourself to the partitioning features available in the Enterprise edition (definition accepted, non-partitioned storage)
9003HY000Promotion refusée : %sSET GLOBAL cluster_role = 'primary' refused after probing the other nodes: primary still reachable, another promotion in progress, peer that still sees the primary, more advanced peer that no longer keeps the missing part of the journal, different databases, writes confirmed to clients (semi-synchronous replication) held by no reachable node, lag greater than max_promotion_lag_mb, database awaiting re-seeding after a table rewritten outside the journal by the primary (waiting to be copied again), node FENCED or being seeded; in raft mode (automatic election), refusal by a voter (node n2 refused: not up to date on database shop (epoch 4 < 5), candidate lacks database …, already voted for …), no reachable majority (cluster has no quorum: 1 of 3 members reachable) or election already in progress (the precise reason follows the colon, in English)Depending on the reason: first demote the former primary ('secondary'), promote another secondary, or force while accepting the loss (SET GLOBAL cluster_role = 'force_primary'); see chapter 17, §17.4
9004HY000Réplication synchrone : %sSemi-synchronous replication (@@cluster_sync_commit set to RECEIVED, APPLIED or MAJORITY): acknowledgments from the secondaries not received within @@cluster_sync_timeout or too few secondaries connected (warning with the FALLBACK behavior, error with ERROR), wait canceled by KILL QUERY (warning), node demoted or removed during the wait (error; quorum lost when an elected leader gives up its role for lack of a majority, raft mode). The write is always committed on the primary (reason in English after the colon)Do not replay the write without re-reading (risk of duplicate); check the secondaries (SHOW CLUSTER STATUS, SYNC column); see chapter 17, §17.8
9005HY000Limite de données de Miraj Express atteinte (%s) : supprimez des données ou utilisez l'édition EntrepriseExpress edition: the total of the tables reaches 20 GB and the statement would grow the data (INSERT, REPLACE, LOAD DATA, UPDATE, CREATE TABLE, ALTER TABLE)Delete data (DELETE, TRUNCATE, DROP, always allowed) or switch to the Enterprise or Cluster edition
1194HY000La table '%s' est marquée comme endommagée et doit être réparée (%s)Special case: reading a table partitioned into segments by the Cluster edition from an edition that cannot read itOpen the table from a server running the Cluster edition

2.6 bis Binary log and binary-log replication errors#

CodeSQLSTATEMessageTypical causeSuggested fix
1186HY000Journal binaire fermé, RESET MASTER impossibleRESET MASTER without --log-binStart the server with --log-bin
1198HY000Cette opération est impossible tant que la réplication tourne ; exécuter d'abord STOP SLAVECHANGE MASTER, RESET SLAVE, SET GLOBAL gtid_slave_pos or sql_slave_skip_counter while the replica threads are runningSTOP SLAVE, then start again
1200HY000Le serveur n'est pas configuré comme réplica ; corriger la configuration ou utiliser CHANGE MASTER TOSTART SLAVE, STOP SLAVE or RESET SLAVE without a prior CHANGE MASTER TO (or embedded engine)CHANGE MASTER TO …
1220HY000Erreur à l'exécution de la commande %s : %sSHOW BINLOG EVENTS on an unknown file or at a position that is not the start of an eventRead the positions with SHOW BINLOG EVENTS without FROM
1236HY000Erreur fatale %s de la source à la lecture du journal binaire : '%s'Source side: journal disabled, unknown file, GTID position missing (purged files) or beyond the journal; replica side: Last_IO_ErrorRe-seed the replica from a copy, then SET GLOBAL gtid_slave_pos
1373HY000Fichier cible absent de l'index du journal binairePURGE BINARY LOGS TO an unknown fileChoose a name from SHOW BINARY LOGS
1381HY000Le journal binaire n'est pas activéSHOW BINARY LOGS, PURGE BINARY LOGS without --log-binStart with --log-bin
1950HY000Tentative de journaliser le GTID %s, dont le numéro de séquence ne suit pas celui du GTID existant %s, alors que gtid_strict_mode est activégtid_strict_mode = ON and an imposed sequence (gtid_seq_no) that does not follow that of the domain; the transaction is rolled backFix gtid_seq_no or turn off gtid_strict_mode

2.7 MIRAJ-specific errors (editions, change events and vectors)#

These codes exist in no other SQL engine; they are specific to MIRAJ.

CodeSQLSTATEMessageTypical causeSuggested fix
9001HY000%s n'est pas disponible dans l'édition Miraj ExpressFeature reserved for the Enterprise or Cluster edition used in the Express edition (e.g. intra-query parallelism)Switch to the Enterprise or Cluster edition if the feature is needed
9002HY000%s demande l'édition Miraj ClusterEffective partitioning feature (segments, EXCHANGE PARTITION on HASH/KEY...) used outside the Cluster editionSwitch to the Cluster edition, or limit yourself to the partitioning features available in the Enterprise edition (definition accepted, non-partitioned storage)
9003HY000Promotion refusée : %sSET GLOBAL cluster_role = 'primary' refused after probing the other nodes: primary still reachable, another promotion in progress, peer that still sees the primary, more advanced peer that no longer keeps the missing part of the journal, different databases, writes confirmed to clients (semi-synchronous replication) held by no reachable node, lag greater than max_promotion_lag_mb, database awaiting re-seeding after a table rewritten outside the journal by the primary (waiting to be copied again), node FENCED or being seeded; in raft mode (automatic election), refusal by a voter (node n2 refused: not up to date on database shop (epoch 4 < 5), candidate lacks database …, already voted for …), no reachable majority (cluster has no quorum: 1 of 3 members reachable) or election already in progress (the precise reason follows the colon, in English)Depending on the reason: first demote the former primary ('secondary'), promote another secondary, or force while accepting the loss (SET GLOBAL cluster_role = 'force_primary'); see chapter 17, §17.4
9004HY000Réplication synchrone : %sSemi-synchronous replication (@@cluster_sync_commit set to RECEIVED, APPLIED or MAJORITY): acknowledgments from the secondaries not received within @@cluster_sync_timeout or too few secondaries connected (warning with the FALLBACK behavior, error with ERROR), wait canceled by KILL QUERY (warning), node demoted or removed during the wait (error; quorum lost when an elected leader gives up its role for lack of a majority, raft mode). The write is always committed on the primary (reason in English after the colon)Do not replay the write without re-reading (risk of duplicate); check the secondaries (SHOW CLUSTER STATUS, SYNC column); see chapter 17, §17.8
9005HY000Limite de données de Miraj Express atteinte (%s) : supprimez des données ou utilisez l'édition EntrepriseSee §2.6See §2.6
900625000WAIT FOR CHANGES n'est pas permis dans une transactionWAIT FOR CHANGES in an explicit transaction, or in an implicit transaction (autocommit = 0) that has writtenCommit or roll back the transaction before waiting; wait on a dedicated connection (chapter 21)
9007HY000Cette session n'a aucun abonnement LISTEN actifWAIT FOR CHANGES without a prior LISTEN on the session, or after UNLISTEN *Subscribe (LISTEN TABLE …, LISTEN channel) before waiting
9008HY000Trop d'abonnements LISTEN (%s permis)More than change_events_max_listeners subscriptions on a single sessionRemove subscriptions (UNLISTEN) or raise change_events_max_listeners
9009HY000La table '%s' n'a pas de clé primaire : seuls les événements de table sont transmisWarning from LISTEN TABLE on a table with no primary key: its writes only give BULK eventsAdd a primary key to receive one event per row
901022001La charge de NOTIFY dépasse %s octetsPayload of NOTIFY or MIRAJ_NOTIFY() longer than change_events_max_payloadSend a shorter payload (an identifier rather than the data) or raise change_events_max_payload
9011HY000Plafond de données de Miraj Developer atteint (%s) ; supprimez des données ou utilisez l'édition ClusterDeveloper edition: the total of the tables reaches 20 GB and the statement would make the data grow (INSERT, REPLACE, LOAD DATA, UPDATE, CREATE TABLE, ALTER TABLE)Delete data (DELETE, TRUNCATE, DROP, always allowed) or move to the Cluster edition
9033HY000Le compte '%s'@'%s' peut se connecter depuis d'autres machines et n'a pas de mot de passe : donnez-lui-en un (IDENTIFIED BY) ou réglez require_password = OFFCREATE USER of an account reachable remotely without a password, or ALTER USER / SET PASSWORD that removes its password, under require_password = ONGive the account a password, or SET GLOBAL require_password = OFF
9012HY000L'édition Miraj Developer est limitée à 24 heures d'utilisation continue ; redémarrez le serveur pour continuerDeveloper edition: 24 hours have elapsed since the process started; every statement is refused, the data remain intactRestart miraj-server (or the application that embeds the engine); the count restarts from zero
9034HY000%s n'est pas permis au niveau d'accès MCP %sSession opened with an MCP token: statement above the token's level (INSERT with a READ token, DDL with a WRITE token…), including in the body of a routine or a trigger; token management from an MCP session, whatever the levelUse a token of a sufficient level, or manage tokens through the main port (chapter 20, §20.5)
9035HY000Le jeton '%s' existe déjàCREATE MCP TOKEN or CREATE API TOKEN with a name already taken on the server, by any account and for either token family (case-insensitive comparison)Choose another name, or drop the old token (DROP MCP TOKEN, DROP API TOKEN)
9036HY000Jeton inconnu '%s'DROP MCP TOKEN, DROP API TOKEN or ALTER API TOKEN of a token that does not exist in this family (warning with IF EXISTS)Check the name with SHOW MCP TOKENS or SHOW API TOKENS
9037HY000La partition %s ne peut pas être placée sur le nœud '%s', qui n'est pas membre d'un cluster actifPARTITION … NODE 'id' outside an active cluster, node outside members or invalid identifierCheck cluster.toml and the node identifier (§17.10)
9038HY000La partition %s de %s est tenue par le nœud %s, injoignable : %sRead or write of a partition dedicated to a node that is stopped, unreachable or does not answer within fragment_timeout_msRestart the node; prune the query to the available partitions
9039HY000%s écrirait dans des partitions tenues par plusieurs nœuds (%s) ; une instruction ou une transaction ne peut écrire que les partitions d'un seul nœudStatement that touches the partitions of several nodes; transaction that writes here and on another node, or on two other nodes (the statement alone fails)Split the statement by node; one transaction per node written
9040HY000La transaction qui écrit les partitions tenues par le nœud %s a été annulée par ce nœud : %sTransaction that writes on another node left idle for more than fragment_timeout_ms (§17.10.5): rolled back here tooReplay the transaction; increase fragment_timeout_ms
9041HY000%s n'est pas pris en charge sur %s tant que la partition %s est tenue par le nœud %sOperation not supported on a table with a dedicated partition (§17.10.9)See §17.10.10
9042HY000Le nœud %s a refusé la demande sur le fragment : %sDifferent definition between nodes, partition not heldWait for the DDL replication to finish, check the placement
9043HY000Aucun nœud disponible pour les connexions %sSent by miraj-proxy in place of the handshake: no primary (election in progress, unreachable nodes) for the write port (RW), no healthy node for the read port (RO)Reconnect after a few seconds; check miraj-proxy status and the proxy journal (chapter 23)
9044HY000Le chemin %s %s est déjà utilisé par l'endpoint %sCREATE ENDPOINT whose method and path shape (equal fixed segments, parameters in the same places) are already taken by another endpoint, across all databasesChoose another path, or replace the existing endpoint (chapter 24, §24.4.2)
9045HY000Chemin d'endpoint invalide '%s' : %sPath without a leading /, empty segment or segment with a forbidden character, badly written or repeated {name} parameter, path under /api or /mcp, more than 255 charactersFix the path (chapter 24, §24.4.2)
9046HY000Paramètre d'endpoint '%s' : %sCall of an endpoint without a value for a parameter that has no DEFAULT (missing value), or with a parameter it does not declare (unknown parameter); returned as HTTP status 400Provide the value (path, query or JSON body), or declare the parameter in PARAMS
9047HY000L'accès REST %s n'est pas permis pour %sREST request of a family (endpoints, tables, SQL) or of an endpoint that the token (CREATE API TOKEN … ACCESS) or the password connections (rest_basic_access) do not allow; returned as HTTP status 403Widen the token's access (ALTER API TOKEN … ACCESS) or rest_basic_access (chapter 24, §24.3)
9048HY000L'hôte '%s' ne peut pas se connecter tant que la base système est indisponible : seules les connexions locales sont acceptéesConnection from a non-loopback address (main port, REST, MCP) to a server that started without being able to open its miraj system database; returned as HTTP status 403 by REST and MCPConnect from the server machine; read the BASE SYSTÈME INDISPONIBLE line in the server log, fix the cause (locked file, disk, permissions) and restart (chapter 16, §16.4.4)
9051HY000Option '%s' invalide pour l'index de texte : %sFULLTEXT index whose column weight (designation WEIGHT n) is zero, negative or non-numeric (a weight must be a positive number); the cited option is the column and its weight as writtenWrite a strictly positive real number, or remove WEIGHT (weight 1) (chapter 7)
9052HY000La distance floue %s est hors limites (0 à 2)Fuzzy search in boolean mode whose suffix attached to the word exceeds 2 (MATCH … AGAINST ('sirop~3' IN BOOLEAN MODE))Write word~1 or word~2 (~0: exact word); see chapter 9, §9.22
9054HY000Le nœud %s utilise le langage SQL %s mais le cluster utilise %s : tous les nœuds d'un cluster doivent avoir le même langage (sql_mode)Joining of a cluster node whose POSTGRESQL element of sql_mode differs from that of the primary; refusal logged by both nodes (server.log)Give all nodes the same sql_mode (language); see chapter 17 and 27.12
905501000%sWarning (note): RAISE NOTICE of a routine written in PL/pgSQL; a PostgreSQL client receives it as a NOTICE message (SQLSTATE 00000)—; see 30.13
905601000%sWarning: RAISE WARNING of a routine written in PL/pgSQL (WARNING message)—; see 30.13
905701000%sWarning (note): RAISE INFO of a routine written in PL/pgSQL (INFO message)—; see 30.13
90582BP01impossible de supprimer la fonction %s car d'autres objets en dépendent : déclencheur %s (utiliser DROP ... CASCADE)DROP FUNCTION in the PostgreSQL language of a function that triggers callDROP FUNCTION … CASCADE (also drops the triggers), or drop the triggers first; see 30.13
9059HY000%s demande une licence Miraj valide (état de la licence : %s) ; voir SHOW LICENSEEnterprise edition feature (change events, MCP, binary log, journal archiving) requested from a server without a valid licenseSHOW LICENSE, then install or renew the license; see chapter 31
9060HY000%s demande une licence Miraj Cluster valide (état de la licence : %s) ; voir SHOW LICENSEPARTITION … NODE, SET GLOBAL cluster_role or cluster_sync_* with a license that does not cover the Cluster editionInstall a Cluster license; see 31.7
9061HY000Plafond de données de %s atteint : ce serveur n'a pas de licence Miraj valide ; installez le fichier de licence (miraj.lic) ou supprimez des donnéesEnterprise or Cluster server without a license whose data reach 20 GB; an expired license does not capInstall the license (--install-license), or delete data; see 31.4
9062HY000Licence refusée : %sFLUSH LICENSE on a file that is unreadable, modified or tied to another machine; the license in place keeps servingReinstall the file received; see 31.2
9063HY000Nœud %s refusé : la licence %s permet %s nœud(s) dans le clusterCluster that has more nodes than its license allows; refusal logged by the primaryA license for more nodes, or remove a node from members; see 31.7
9064HY000Nœud %s refusé : sa licence (%s) n'est pas celle du cluster (%s)Different miraj.lic file on this node; refusal logged by the primaryInstall the cluster license on this node; see 31.7
9065HY000%s n'est pas disponible dans l'édition Miraj DeveloperEncryption at rest requested in the Developer edition (data_encryption, ENCRYPTION='Y', encrypted folder)Use the Enterprise or Cluster edition (chapter 25)
9066HY000%s exige le chiffrement des données, qui n'a pas été activé à l'initialisation de ce serveurENCRYPTION='Y' or ALTER INSTANCE ROTATE MASTER KEY on a data folder that is not encryptedEncryption is enabled when a new folder is initialized (chapter 25, §25.2)
9067HY001Mémoire du serveur insuffisante : les instructions en cours sur le serveur dépasseraient max_server_memory (%s) ; réessayez plus tardSorts, groupings, DISTINCT, windows and joins of all running statements together would exceed max_server_memory (half of the physical memory by default); transient condition, depends on the other sessions (53200 in the PostgreSQL language)Retry later; raise max_server_memory (SET GLOBAL); see 16.4.5
9085HY000Document XML mal formé à la ligne %s : %sMalformed LOAD XML file (unclosed or crossed tag, unknown entity, unquoted attribute…); nothing is loadedFix the document at the indicated line; see 8.8
6138HY000Données impossibles à convertir en vecteur valide : '%s'Value not convertible to VECTOR(n)Fix the value format (text form […] or binary)
760022000dimensions de vecteurs différentes %s et %sOperation between two vectors of different dimensionsUse vectors of the same dimension
760122000%s dimensions attendues, et non %sVector written to a VECTOR(n) column with a dimension different from nAdjust the number of components
760222P02syntaxe incorrecte pour le type vector : "%s"Invalid text form of a vectorUse the form [v1, v2, ...]
760322000NaN interdit dans un vecteurNaN component in a vectorRemove NaN values upstream
760422000valeur infinie interdite dans un vecteurInfinite component in a vectorRemove infinite values upstream
4206HY000Impossible de déterminer le type de distance de VEC_DISTANCE : aucun index trouvéVEC_DISTANCE called without a vector index on one of its columnsCreate a VECTOR INDEX on the column (chapter 11) or spell out the metric: VEC_DISTANCE_EUCLIDEAN, VEC_DISTANCE_COSINE

2.8 Internal and miscellaneous errors#

CodeSQLSTATEMessageTypical causeSuggested fix
1024HY000Erreur de lecture du fichier '%s' (errno : %s)Disk error when reading an engine fileCheck the disk, restore from a backup if the file is damaged
1021HY000Disque plein (%s) : l'écriture a été refusée, libérez de l'espace puis réessayezFree space of the data volume below min_free_disk_space (512 MiB by default), or volume actually full; the refused write has no effect (53100 in the PostgreSQL language)Free up space (DELETE, TRUNCATE, DROP remain allowed); see 16.4.5
1026HY000Erreur d'écriture du fichier '%s' (errno : %s)Disk error on write (permissions...); in particular, failed flush of the journal to disk: the database journal is stopped, no more writes are accepted in it (58030 in the PostgreSQL language)Check the disk and the permissions; for a stopped journal, fix the cause then restart the server (11.4.2)
1038HY001Mémoire de tri insuffisante : l'instruction dépasse max_statement_memory (%s)Sort of a statement beyond max_statement_memory (2 GiB by default); the session remains usable (53200 in the PostgreSQL language)Restrict the query (WHERE, LIMIT), or raise max_statement_memory for the session; see 16.4.5
1114HY000La table '%s' est pleineGrouping, DISTINCT, window, set operation, hash join or intermediate result beyond max_statement_memory (the table cited is then #sql_tmp (…)); or disk full while writing a table (53100 in the PostgreSQL language in both cases)As 1038, or as 1021 for a full disk
1028HY000Tri interrompu : %sORDER BY interrupted (e.g. by KILL or a limit on examined rows)See the message for the precise cause; rerun if the interruption was not intended
1105HY000Erreur inconnue : %sUnexpected internal error (engine bug, corrupted routine/trigger definitions file...)Report the error with the full context; check the integrity of the files of the database concerned
114842000Cette commande n'est pas autorisée avec cette version du serveurCommand refused by the network protocol (e.g. LOCAL INFILE refused by a client that does not accept it)Check the client configuration
1193HY000Variable système inconnue : '%s'SET/SELECT @@variable on a variable name that does not existCheck the exact name in SHOW VARIABLES
123142000La variable '%s' ne peut pas recevoir la valeur '%s'Value outside the expected domain for a system variable; for a Boolean variable (autocommit, read_only, local_infile, and also those accepted without effect such as unique_checks, sql_notes, sql_safe_updates, big_tables), any value other than ON, OFF, 1, 0, TRUE, FALSE or DEFAULT (SET autocommit = 2, = 'yes', = NULL); the variable keeps its valueSee the variable's documentation for the allowed values
123542000Cette version de Miraj ne prend pas encore en charge '%s'Syntactically valid construct but not implemented in this versionUse an equivalent supported construct

2.9 Stored program errors (procedures, functions, triggers, events)#

CodeSQLSTATEMessageTypical causeSuggested fix
130442000%s %s existe déjàCREATE PROCEDURE or CREATE FUNCTION of a name already taken in the database (PROCEDURE pr existe déjà)CREATE OR REPLACE, IF NOT EXISTS, or another name
130542000%s %s n'existe pasCALL of a missing procedure (PROCEDURE shop.nopr n'existe pas), GRANT on a missing routine, ROLLBACK TO SAVEPOINT of an unknown point (SAVEPOINT nom n'existe pas)Check the name and the database
131842000Nombre d'arguments incorrect pour %s %s : %s attendus, %s reçusCALL or function call with too many or too few argumentsCheck the parameter list (SHOW CREATE PROCEDURE)
132042000Aucun RETURN dans la FUNCTION %sCREATE FUNCTION whose body contains no RETURNAdd the RETURN
13212F005La FUNCTION %s s'est terminée sans RETURNExecution of a function that reaches the end of its body without going through a RETURNAdd a RETURN on every path
132624000Le curseur n'est pas ouvertFETCH or CLOSE of a cursor before its OPENOPEN first
132902000Aucune donnée : aucune ligne lue, sélectionnée ou traitéeFETCH after the last row of a cursor without a NOT FOUND handlerDECLARE CONTINUE HANDLER FOR NOT FOUND SET fini = 1
133920000Aucun cas ne correspond dans l'instruction CASECASE statement of a routine without ELSE where no branch appliesAdd an ELSE branch
1359HY000Le déclencheur '%s' existe déjàCREATE TRIGGER of a name already takenCREATE OR REPLACE TRIGGER, or another name
1360HY000Le déclencheur n'existe pasDROP TRIGGER of a missing triggerDROP TRIGGER IF EXISTS
1422HY000Validation explicite ou implicite interdite dans une fonction stockée ou un déclencheurCOMMIT, ROLLBACK, DDL or account management in the body of a function or a triggerMove the statement into a procedure called outside the trigger
1442HY000Impossible de modifier la table '%s' dans une fonction stockée ou un déclencheur : elle est déjà utilisée par l'instruction qui l'a appeléTrigger (or function) that writes into the table of the statement that fired itWrite into another table, or do the computation with SET NEW.col in a BEFORE trigger
1537HY000L'événement '%s' existe déjàCREATE EVENT of a name already takenCREATE EVENT IF NOT EXISTS or ALTER EVENT
1539HY000Événement inconnu '%s'DROP EVENT or ALTER EVENT of a missing eventDROP EVENT IF EXISTS
164445000 (celui du SIGNAL)texte de MESSAGE_TEXTSIGNAL SQLSTATE '45000' SET MESSAGE_TEXT = 'Stock insuffisant' in a routine: ERROR 1644 (45000): Stock insuffisantIntended application error; handle it with a handler (DECLARE … HANDLER FOR SQLSTATE '45000') or on the client side

3. The SQLSTATE#

The SQLSTATE is a code of exactly 5 characters (digits and uppercase letters), standardized independently of MIRAJ and shared by most SQL engines. An application can rely on it for generic handling, without knowing the wording or even the MIRAJ-specific numeric code — useful when porting code written against another SQL engine.

A few classes worth knowing:

SQLSTATEMeaningExamples of MIRAJ codes
42000 (and the 42Sxx)Syntax error or access rule violation1064, 1049, 1050, 1051, 1054
23000Integrity constraint violation1048, 1062, 1451, 1452, 4025
3D000No database selected1046
28000Invalid authorization (authentication)1045
40001Serialization failure, transaction rolled back (deadlock or concurrency conflict)1213
22000 and derivatives (22001, 22003, 22007, 22012...)Data exception: truncation, overflow, division by zero1264, 1292, 1365, 1366, 1406
25006Statement forbidden in a read-only transaction1792
70100Interrupted statement (SQLSTATE from a widespread convention in the SQL ecosystem, adopted by MIRAJ)1317, 1927, 1969
HY000General error, with no more specific SQLSTATE classthe majority of engine-specific errors (1004, 1105, 1193, 9001, 9002, 9003, 9004, 9005...)

Recommended usage on the application side: a driver (ODBC, JDBC, ADO.NET...) generally exposes the SQLSTATE alongside the native code. For portable handling across engines (retrying a transaction on 40001, distinguishing a 23000 constraint error from a 42000 syntax error), rely on the SQLSTATE. For precise MIRAJ-specific diagnosis (displaying a suitable message, distinguishing two causes that share the same SQLSTATE), rely on the numeric code from this page.

When no more specific SQLSTATE is defined for a code, MIRAJ returns HY000 by default (including for a code entirely unknown to the catalog).

An error raised by a stored routine with SIGNAL SQLSTATE '45000' SET MESSAGE_TEXT = '...' carries the SQLSTATE chosen by the routine rather than the one associated with the generic numeric code of SIGNAL — this is the normal mechanism for raising an application error with a custom SQLSTATE (class 45 reserved for this use).

3.1 PostgreSQL-language instance#

On an instance in the PostgreSQL language (§ 16.10, chapter 30), the client receives only the SQLSTATE and the message: the codes that PostgreSQL drivers recognize replace the generic SQLSTATE of the MIRAJ code.

SQLSTATEMeaningMIRAJ codes or cases
42601syntax error1064; also MIRAJ-specific syntax that is refused (backticks, LIMIT a, b, &&…), whose message names the construct ("… is MIRAJ syntax, not accepted in the PostgreSQL language"); ? or :name parameter in a prepared query
0A000feature not supported1235; PL/pgSQL construct outside the supported subset (the message names it), CREATE EVENT, array-type column, recursive view…
22P02unreadable written value'peut-être'::boolean, '\xZZ'::bytea, badly written interval
42P01, 42703, 23505, 23502, 23503, 23514missing table, unknown column, duplicate, NULL not allowed, foreign key, CHECK1146, 1054, 1062, 1048, 1451/1452, 4025
42P06, 3F000database (schema) already existing; unknown, absent on drop, or not selected1007; 1049, 1008, 1046
3D000unknown database named at connection (notice, the session opens with no current database)database parameter
22023inconsistent sequence options4085
54000limit exceeded: depth of a recursive expression, number of rows of generate_series3636
54001statement too complex7620
53100disk full, table full1021, 1114 (also when max_statement_memory causes it)
53200out of memory1038, 9067
58030I/O error: journal stopped by a failed flush to disk1026
42P07table already exists1050
42501insufficient privilege1044, 1142, 1143, 1227
55P03lock wait timeout exceeded1205
57014query cancelled1317, 3024 (Ctrl-C, KILL QUERY, timeout)
25P01DECLARE … CURSOR outside a transaction blockWITHOUT HOLD cursor
25P02failed transaction blockstatement other than the end of the block after an error
34000unknown portal or cursorFETCH, CLOSE, Execute
26000, 42P05, 42P03unknown prepared statement, name already taken, cursor already openextended protocol, DECLARE
42P11invalid cursor definitionDECLARE c CURSOR FOR INSERT … (statement without rows), SCROLL and NO SCROLL together
55000object in the wrong statelastval() before any number served to the session, currval before nextval, moving backwards in a NO SCROLL cursor
428C9column that cannot be assignedvalue written into a GENERATED ALWAYS AS IDENTITY column (without OVERRIDING SYSTEM VALUE) or into a generated column
42P10inconsistent column listON CONFLICT without an arbiter unique constraint, too many column aliases (AS x (a, b)), DISTINCT ON that does not start the ORDER BY
42883function or operator does not existunknown function, wrong number or type of arguments (lower(1))
42804incompatible typebit string written into a column of another type, result of a set function with another structure
22012division by zero1 / 0, mod(x, 0)
55P02parameter cannot be changed in the sessionSET shared_buffers, max_connections…
57P01, 57P05, 25P03connection closed by the server (FATAL)KILL, pg_terminate_backend, server shutdown; idle timeout; idle-in-transaction timeout
42602, 58P02relative path, existing fileCOPY … TO 'file'
22021text that is not UTF-8client_encoding other than UTF-8
28000, 28P01connection refused, wrong password1045, TLS required
08P01protocol violationmalformed message, packet too long (1153)
XX000internal error or no equivalentcodes with SQLSTATE HY000

4. Message language#

MIRAJ error messages exist in several languages: French, English, and eight additional languages (Chinese, Hindi, Spanish, Arabic, Portuguese, Russian, German, Japanese). This page documents the French wording, the reference language of this manual.

To obtain the messages in English (or in another available language):

  • the --lang option of miraj-server (en, fr, zh, hi, es, ar, pt, ru, de, ja), or of miraj-cli opened on a data folder, selects the language of error messages and warnings (SHOW WARNINGS, MIRAJ language: Données tronquées pour la colonne 'v' à la ligne 1 for 1265 in French); in the MIRAJ language, the warnings and notes listed by SHOW WARNINGS are written in the same language as the errors (for example, under --lang fr, Warning | 1265 | Données tronquées pour la colonne 'v' à la ligne 1), their code remaining the same;
  • each error can also be reworded in a given language without changing the session language, if the API or tool used exposes this feature (on-demand retranslation from the error's code and arguments);
  • <language>.json files placed next to the server executable allow you to complete or replace the embedded translations, including to add a language not listed above.

The numeric code and the SQLSTATE of an error never change with the language: only the message text is translated. An application that tests the code or the SQLSTATE (rather than the message text) therefore works identically regardless of the language configured on the server.