From: Nikita Pettik <korablev@tarantool.org>
To: Vladislav Shpilevoy <v.shpilevoy@tarantool.org>
Cc: tarantool-patches@dev.tarantool.org
Subject: Re: [Tarantool-patches] [PATCH 4/4] sql: do not force FP representation for NUMBER field
Date: Tue, 11 Feb 2020 17:14:45 +0300 [thread overview]
Message-ID: <20200211141445.GA8095@tarantool.org> (raw)
In-Reply-To: <4b6e4e38-ff15-fa1f-6c5b-862b6775d283@tarantool.org>
On 11 Feb 00:24, Vladislav Shpilevoy wrote:
> Thanks for the patch, Mergen too!
>
> > diff --git a/test/sql-tap/numcast.test.lua b/test/sql-tap/numcast.test.lua
> > index 87c5f6b35..f795cef75 100755
> > --- a/test/sql-tap/numcast.test.lua
> > +++ b/test/sql-tap/numcast.test.lua
> > @@ -191,4 +191,64 @@ test:do_execsql_test(
> > 10, 10
> > })
> >
> > +test:do_execsql_test(
> > + "numcast-3.6",
> > + [[
> > + CREATE TABLE t1 (id INT PRIMARY KEY, n NUMBER);
> > + INSERT INTO t1 VALUES (1, 9223372036854775807);
> > + INSERT INTO t1 VALUES (2, -9223372036854775807);
> > + INSERT INTO t1 VALUES (3, 9223372036854775807.1);
> > + SELECT n, n/100 FROM t1;
> > + ]], {
> > + 9223372036854775807ULL, 92233720368547758ULL,
> > + -9223372036854775807LL, -92233720368547758LL,
> > + 9223372036854775808, 92233720368547758.08
>
> Could you please select smaller values for the test, in
> case the big values don't matter here? Because
> 9223372036854775807.1 turned into 9223372036854775808 looks
> confusing.
Ok:
diff --git a/test/sql-tap/numcast.test.lua b/test/sql-tap/numcast.test.lua
index f795cef75..eeac5353a 100755
--- a/test/sql-tap/numcast.test.lua
+++ b/test/sql-tap/numcast.test.lua
@@ -197,12 +197,12 @@ test:do_execsql_test(
CREATE TABLE t1 (id INT PRIMARY KEY, n NUMBER);
INSERT INTO t1 VALUES (1, 9223372036854775807);
INSERT INTO t1 VALUES (2, -9223372036854775807);
- INSERT INTO t1 VALUES (3, 9223372036854775807.1);
+ INSERT INTO t1 VALUES (3, 9007199254740992.0);
SELECT n, n/100 FROM t1;
]], {
9223372036854775807ULL, 92233720368547758ULL,
-9223372036854775807LL, -92233720368547758LL,
- 9223372036854775808, 92233720368547758.08
+ 9007199254740992, 90071992547409.92
})
next prev parent reply other threads:[~2020-02-11 14:14 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-05 16:19 [Tarantool-patches] [PATCH 0/4] sql: fix NUMBER conversion issues Nikita Pettik
2020-02-05 16:19 ` [Tarantool-patches] [PATCH 1/4] sql: remove cast to INT during FP arithmetic ops Nikita Pettik
2020-02-05 16:19 ` [Tarantool-patches] [PATCH 2/4] sql: refactor sqlVdbeMemNumerify() Nikita Pettik
2020-02-10 23:25 ` Vladislav Shpilevoy
2020-02-11 14:14 ` Nikita Pettik
2020-02-11 22:17 ` Vladislav Shpilevoy
2020-02-05 16:19 ` [Tarantool-patches] [PATCH 3/4] sql: fix CAST AS NUMBER operator Nikita Pettik
2020-02-10 23:24 ` Vladislav Shpilevoy
2020-02-11 14:14 ` Nikita Pettik
2020-02-11 22:17 ` Vladislav Shpilevoy
2020-02-11 23:20 ` Nikita Pettik
2020-02-11 23:27 ` Vladislav Shpilevoy
2020-02-12 14:10 ` Nikita Pettik
2020-02-05 16:19 ` [Tarantool-patches] [PATCH 4/4] sql: do not force FP representation for NUMBER field Nikita Pettik
2020-02-10 23:24 ` Vladislav Shpilevoy
2020-02-11 14:14 ` Nikita Pettik [this message]
2020-02-09 17:39 ` [Tarantool-patches] [PATCH 0/4] sql: fix NUMBER conversion issues Vladislav Shpilevoy
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=20200211141445.GA8095@tarantool.org \
--to=korablev@tarantool.org \
--cc=tarantool-patches@dev.tarantool.org \
--cc=v.shpilevoy@tarantool.org \
--subject='Re: [Tarantool-patches] [PATCH 4/4] sql: do not force FP representation for NUMBER field' \
/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