summaryrefslogtreecommitdiffstats
path: root/mysql-test/main/mysql-metadata.result
blob: 1530465eaf8bd965dcc807854d2361a7b1c2ff38 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
#
# MDEV-17832 Protocol: extensions for Pluggable types and JSON, GEOMETRY
#
SET NAMES utf8;
CREATE TABLE t1 (
js0 JSON,
js1 TEXT CHECK (JSON_VALID(js1)),
js2 TEXT CHECK (LENGTH(js2) > 0 AND JSON_VALID(js2)),
js3 TEXT CHECK (LENGTH(js2) > 0 OR JSON_VALID(js2))
) CHARACTER SET utf8;
--------------
SELECT * FROM t1
--------------

Field   1:  `js0`
Org_field:  `js0`
Catalog:    `def`
Database:   `test`
Table:      `t1`
Org_table:  `t1`
Type:       BLOB (format=json)
Collation:  latin1_swedish_ci (8)
Length:     4294967295
Max_length: 0
Decimals:   0
Flags:      BLOB BINARY 

Field   2:  `js1`
Org_field:  `js1`
Catalog:    `def`
Database:   `test`
Table:      `t1`
Org_table:  `t1`
Type:       BLOB (format=json)
Collation:  latin1_swedish_ci (8)
Length:     65535
Max_length: 0
Decimals:   0
Flags:      BLOB 

Field   3:  `js2`
Org_field:  `js2`
Catalog:    `def`
Database:   `test`
Table:      `t1`
Org_table:  `t1`
Type:       BLOB (format=json)
Collation:  latin1_swedish_ci (8)
Length:     65535
Max_length: 0
Decimals:   0
Flags:      BLOB 

Field   4:  `js3`
Org_field:  `js3`
Catalog:    `def`
Database:   `test`
Table:      `t1`
Org_table:  `t1`
Type:       BLOB
Collation:  latin1_swedish_ci (8)
Length:     65535
Max_length: 0
Decimals:   0
Flags:      BLOB 


0 rows in set (TIME)

Bye
--------------
SELECT JSON_COMPACT(js0) FROM t1
--------------

Field   1:  `JSON_COMPACT(js0)`
Org_field:  ``
Catalog:    `def`
Database:   ``
Table:      ``
Org_table:  ``
Type:       LONG_BLOB (format=json)
Collation:  latin1_swedish_ci (8)
Length:     4294967295
Max_length: 0
Decimals:   0
Flags:      BINARY 


0 rows in set (TIME)

Bye
DROP TABLE t1;