Tarantool development patches archive
 help / color / mirror / Atom feed
From: Vladislav Shpilevoy <v.shpilevoy@tarantool.org>
To: tarantool-patches@freelists.org, Nikita Pettik <korablev@tarantool.org>
Subject: [tarantool-patches] Re: [PATCH 1/2] sql: make type in column-meta be consistent with NoSQL names
Date: Thu, 21 Mar 2019 12:03:32 +0300	[thread overview]
Message-ID: <ca5e7931-f595-9475-d97b-cbe24608aa13@tarantool.org> (raw)
In-Reply-To: <2bb818aa4a68f456c5460cdaa3a519bd1bb57e2f.1552327461.git.korablev@tarantool.org>

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.

  reply	other threads:[~2019-03-21  9:03 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-11 18:10 [tarantool-patches] [PATCH 0/2] SQL types fixes Nikita Pettik
2019-03-11 18:10 ` [tarantool-patches] [PATCH 1/2] sql: make type in column-meta be consistent with NoSQL names Nikita Pettik
2019-03-21  9:03   ` Vladislav Shpilevoy [this message]
2019-03-21 14:00   ` [tarantool-patches] " Konstantin Osipov
2019-03-11 18:10 ` [tarantool-patches] [PATCH 2/2] sql: don't change type of function's retval after codegen Nikita Pettik
2019-03-21  9:03   ` [tarantool-patches] " Vladislav Shpilevoy
2019-03-21 12:51     ` n.pettik
2019-03-21 14:46       ` Vladislav Shpilevoy
2019-04-03  7:58 ` [tarantool-patches] Re: [PATCH 0/2] SQL types fixes 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=ca5e7931-f595-9475-d97b-cbe24608aa13@tarantool.org \
    --to=v.shpilevoy@tarantool.org \
    --cc=korablev@tarantool.org \
    --cc=tarantool-patches@freelists.org \
    --subject='[tarantool-patches] Re: [PATCH 1/2] sql: make type in column-meta be consistent with NoSQL names' \
    /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