[tarantool-patches] Re: [PATCH 1/2] sql: make type in column-meta be consistent with NoSQL names
Vladislav Shpilevoy
v.shpilevoy at tarantool.org
Thu Mar 21 12:03:32 MSK 2019
Hi! Thanks for the patch! See 2 comments below.
On 11/03/2019 21:10, Nikita Pettik wrote:
> Column meta-information which is sent alongside execution result via
> IProto protocol, contains string representation of column type.
> In some cases, name of type is different from actual type of field. For
> instance, if column has type SCALAR, string representation in
> meta-information will be "BLOB"; for NUMBER NoSQL type - it will be
> "NUMERIC"; for STRING - "TEXT". Instead of this mess, let's always return
> exact name of underlying NoSQL type.
1. As I know, Kostja deliberately kept SQL names different from NoSQL names,
because SQL has strict standard typing != Tarantool one's. Please, ask him
if your renaming is ok.
> ---
> src/box/sql/select.c | 31 ++-----------
> test/sql/errinj.result | 2 +-
> test/sql/gh-2362-select-access-rights.result | 4 +-
> test/sql/iproto.result | 68 ++++++++++++++--------------
> 4 files changed, 41 insertions(+), 64 deletions(-)
>
> diff --git a/test/sql/errinj.result b/test/sql/errinj.result
> index 0f6075b13..6763faf63 100644
> --- a/test/sql/errinj.result
> +++ b/test/sql/errinj.result
> @@ -115,7 +115,7 @@ select_res
> ---
> - metadata:
> - name: '1'
> - type: INTEGER
> + type: integer
2. Not sure, if lowcase is ok. As I know, all SQL identifiers, keywords
should be stored and returned in uppercase (according to what I heard
from the one, who did the patch for uppercasing everything). Please,
consult Kostja, and check out other vendors for that.
More information about the Tarantool-patches
mailing list