From: Vladislav Shpilevoy <v.shpilevoy@tarantool.org> To: tarantool-patches@freelists.org, imeevma@tarantool.org Subject: [tarantool-patches] Re: [PATCH v1 5/9] sql: make SQL_TARANTOOL_ERROR the only errcode of OP_Halt Date: Sun, 2 Jun 2019 18:35:11 +0200 [thread overview] Message-ID: <ef5273f4-00f5-300a-f909-4859ef031fc4@tarantool.org> (raw) In-Reply-To: <dbfcff193384504fb590a65978cd71b91b39e5c9.1559043251.git.imeevma@gmail.com> > * This routine is invoked once per CTE by the parser while parsing a > diff --git a/src/box/sql/expr.c b/src/box/sql/expr.c > index 6ac42d7..a4a2d71 100644 > --- a/src/box/sql/expr.c > +++ b/src/box/sql/expr.c > @@ -4386,9 +4386,10 @@ sqlExprCodeTarget(Parse * pParse, Expr * pExpr, int target) > ON_CONFLICT_ACTION_IGNORE, 0, > pExpr->u.zToken, 0); > } else { > - sqlHaltConstraint(pParse, SQL_CONSTRAINT_TRIGGER, > - pExpr->on_conflict_action, > - pExpr->u.zToken, 0, 0); > + sqlVdbeAddOp4(v, OP_Halt, SQL_TARANTOOL_ERROR, > + pExpr->on_conflict_action, 0, > + pExpr->u.zToken, 0); > + sqlVdbeChangeP5(v, ER_SQL_EXECUTE); Please, remove p5 arg and store error code in p2. Now it can be done with ease. > } > break; > }
next prev parent reply other threads:[~2019-06-02 16:35 UTC|newest] Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-05-28 11:39 [tarantool-patches] [PATCH v1 0/9] sql: set errors in VDBE using diag_set() imeevma 2019-05-28 11:39 ` [tarantool-patches] [PATCH v1 1/9] sql: remove mayAbort field from struct Parse imeevma 2019-05-28 11:39 ` [tarantool-patches] [PATCH v1 2/9] sql: remove error codes SQL_TARANTOOL_*_FAIL imeevma 2019-05-28 11:39 ` [tarantool-patches] [PATCH v1 3/9] sql: remove error ER_SQL imeevma 2019-05-28 11:39 ` [tarantool-patches] [PATCH v1 4/9] sql: rework diag_set() in OP_Halt imeevma 2019-06-02 16:35 ` [tarantool-patches] " Vladislav Shpilevoy 2019-06-03 8:41 ` Imeev Mergen 2019-06-04 19:34 ` Vladislav Shpilevoy 2019-06-08 12:11 ` Mergen Imeev 2019-05-28 11:39 ` [tarantool-patches] [PATCH v1 5/9] sql: make SQL_TARANTOOL_ERROR the only errcode of OP_Halt imeevma 2019-06-02 16:35 ` Vladislav Shpilevoy [this message] 2019-06-03 11:53 ` [tarantool-patches] " Mergen Imeev 2019-06-04 19:34 ` Vladislav Shpilevoy 2019-06-08 12:15 ` Mergen Imeev 2019-05-28 11:39 ` [tarantool-patches] [PATCH v1 6/9] sql: remove error SQL_INTERRUPT imeevma 2019-05-28 11:39 ` [tarantool-patches] [PATCH v1 7/9] sql: remove error SQL_MISMATCH imeevma 2019-05-28 11:39 ` [tarantool-patches] [PATCH v1 8/9] sql: use diag_set() to set an error in SQL functions imeevma 2019-06-02 16:35 ` [tarantool-patches] " Vladislav Shpilevoy 2019-06-03 11:54 ` Mergen Imeev 2019-05-28 11:39 ` [tarantool-patches] [PATCH v1 9/9] sql: set errors in VDBE using diag_set() imeevma 2019-06-02 16:34 ` [tarantool-patches] " Vladislav Shpilevoy 2019-06-03 12:10 ` Mergen Imeev 2019-06-03 12:20 ` Mergen Imeev 2019-06-09 17:14 ` [tarantool-patches] Re: [PATCH v1 0/9] " Vladislav Shpilevoy 2019-06-13 9:44 ` Kirill Yukhin
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=ef5273f4-00f5-300a-f909-4859ef031fc4@tarantool.org \ --to=v.shpilevoy@tarantool.org \ --cc=imeevma@tarantool.org \ --cc=tarantool-patches@freelists.org \ --subject='[tarantool-patches] Re: [PATCH v1 5/9] sql: make SQL_TARANTOOL_ERROR the only errcode of OP_Halt' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox