[tarantool-patches] [PATCH 0/5] Introduce VARBINARY in SQL

Nikita Pettik korablev at tarantool.org
Wed Jul 24 14:42:42 MSK 2019


Branch: https://github.com/tarantool/tarantool/tree/np/sql-introduce-blob
Issue: https://github.com/tarantool/tarantool/issues/4206

This patch-set introduces new column type available in SQL - VARBINARY.
All values of VARBINARY type are stored as MP_BIN format type in
msgpack. Basically, prior to the current patch all literals starting
with x'...' format were assumed to be encoded with MP_BIN type when
were inserted into SCALAR field. This rule has been remained.
According to ANSI, values of VARBINARY type can't be converted to
any other type.

Nikita Pettik (5):
  sql: always erase numeric flag after stringifying
  sql: fix resulting type calculation for CASE-WHEN stmt
  sql: use 'varbinary' as a name of type instead of 'blob'
  sql: make built-ins raise errors for varbin args
  sql: introduce VARBINARY column type

 extra/mkkeywordhash.c                      |   1 +
 src/box/lua/lua_sql.c                      |   2 +-
 src/box/sql/expr.c                         |  29 ++-
 src/box/sql/func.c                         |  32 ++-
 src/box/sql/parse.y                        |   3 +-
 src/box/sql/vdbe.c                         |  38 ++--
 src/box/sql/vdbeInt.h                      |   2 +-
 src/box/sql/vdbeapi.c                      |   4 +-
 src/box/sql/vdbemem.c                      |  14 +-
 test/sql-tap/cast.test.lua                 |   4 +-
 test/sql-tap/func.test.lua                 |   2 +-
 test/sql-tap/keyword1.test.lua             |   3 +-
 test/sql-tap/lua_sql.test.lua              |   4 +-
 test/sql-tap/position.test.lua             |  16 +-
 test/sql/gh-3888-values-blob-assert.result |   4 +-
 test/sql/iproto.result                     |   4 +-
 test/sql/misc.result                       |   2 +-
 test/sql/types.result                      | 315 +++++++++++++++++++++++++++--
 test/sql/types.test.lua                    |  68 +++++++
 19 files changed, 473 insertions(+), 74 deletions(-)

-- 
2.15.1





More information about the Tarantool-patches mailing list