Skip to content

Commit

Permalink
test jsonb
Browse files Browse the repository at this point in the history
  • Loading branch information
kwannoel committed Oct 30, 2024
1 parent 0ff2d48 commit 2ab4fd4
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions e2e_test/source_inline/tvf/mysql_query.slt
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ CREATE TABLE test (
v18 longblob,
v19 date,
v20 time,
v21 timestamp
v21 timestamp,
v22 json
);
INSERT INTO test SELECT
1 as id,
Expand All @@ -54,16 +55,17 @@ INSERT INTO test SELECT
x'19' as v18,
'2021-01-01' as v19,
'12:34:56' as v20,
'2021-01-01 12:34:56' as v21;
'2021-01-01 12:34:56' as v21,
JSON_OBJECT('key1', 1, 'key2', 'abc');
"

query
select * from mysql_query('$MYSQL_HOST', '$MYSQL_TCP_PORT', '$RISEDEV_MYSQL_USER', '$MYSQL_PWD', 'tvf', 'select * from test;');
----
1 t 1 2 3 4 5 6 7 1.08 1.09 1.10 1.11 char varchar \x000a \x16 \x17 \x18 \x19 2021-01-01 12:34:56 2021-01-01 12:34:56+00:00
1 t 1 2 3 4 5 6 7 1.08 1.09 1.10 1.11 char varchar \x000a \x16 \x17 \x18 \x19 2021-01-01 12:34:56 2021-01-01 12:34:56+00:00 {"key1": 1, "key2": "abc"}

system ok
mysql -e "
USE tvf;
DROP DATABASE tvf;
"
"

0 comments on commit 2ab4fd4

Please sign in to comment.