[tarantool-patches] Re: [PATCH v1 1/1] sql: rework five syntax errors
n.pettik
korablev at tarantool.org
Thu Feb 21 22:01:22 MSK 2019
> On 21 Feb 2019, at 18:40, imeevma at tarantool.org wrote:
>
> This patch reworks five syntax errors.
Why only five? There are 10 errors at all, so lets finish this part
adding all syntax errors.
> These SQL errors were
> converted into Tarantool errors.
>
> Part of #3965
> ---
> https://github.com/tarantool/tarantool/issues/3965
> https://github.com/tarantool/tarantool/tree/imeevma/gh-3965-use-diag_set-to-describe-error
>
> diff --git a/src/box/errcode.h b/src/box/errcode.h
> index 1523b19..1807151 100644
> --- a/src/box/errcode.h
> +++ b/src/box/errcode.h
> @@ -230,6 +230,11 @@ struct errcode_record {
> /*175 */_(ER_SQL_NO_SUCH_PRAGMA, "Pragma '%s' does not exist") \
> /*176 */_(ER_SQL_CANT_RESOLVE_FIELD, "Can’t resolve field '%s'") \
> /*177 */_(ER_INDEX_EXISTS_IN_SPACE, "Index '%s' already exists in space '%s'") \
> + /*178 */_(ER_SQL_SYNTAX, "Syntax error in %s: %s") \
> + /*179 */_(ER_SQL_STACK_OVERFLOW, "Failed to parse SQL statement: parser stack limit reached") \
> + /*180 */_(ER_SQL_SELECT_WILDCARD, "Failed to expand '*' in SELECT statement without FROM clause") \
> + /*181 */_(ER_SQL_STATEMENT_EMPTY, "Failed to execute an empty SQL statement") \
I’ve already said that: why do we consider empty query as an error? Don’t understand.
The rest is ok as obvious.
More information about the Tarantool-patches
mailing list