You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-07-29 08:21:15 +03:00
charsets support for regexp funcions
This commit is contained in:
@ -537,4 +537,106 @@ t1_TIME REGEXP_REPLACE(t1_TIME, '22$', 'KittyCat')
|
||||
01:08:59 01:08:59
|
||||
22:12:02 22:12:02
|
||||
23:59:59 23:59:59
|
||||
SET character_set_connection = 'utf8';
|
||||
CREATE TABLE t2 (hello text) engine columnstore;
|
||||
INSERT INTO t2 values('こんにちは');
|
||||
INSERT INTO t2 values('привет');
|
||||
INSERT INTO t2 values('Γεια');
|
||||
INSERT INTO t2 values('სალამი');
|
||||
SELECT hello, hello regexp 'ん.ち' from t2;
|
||||
hello hello regexp 'ん.ち'
|
||||
こんにちは 0
|
||||
привет 0
|
||||
Γεια 0
|
||||
სალამი 0
|
||||
SELECT hello, hello regexp 'и.е' from t2;
|
||||
hello hello regexp 'и.е'
|
||||
こんにちは 0
|
||||
привет 0
|
||||
Γεια 0
|
||||
სალამი 0
|
||||
SELECT hello, hello regexp 'ε.α' from t2;
|
||||
hello hello regexp 'ε.α'
|
||||
こんにちは 0
|
||||
привет 0
|
||||
Γεια 0
|
||||
სალამი 0
|
||||
SELECT hello, hello regexp 'ა.ა' from t2;
|
||||
hello hello regexp 'ა.ა'
|
||||
こんにちは 0
|
||||
привет 0
|
||||
Γεια 0
|
||||
სალამი 0
|
||||
SELECT hello, regexp_substr(hello, 'ん.ち') from t2;
|
||||
hello regexp_substr(hello, 'ん.ち')
|
||||
こんにちは
|
||||
привет
|
||||
Γεια
|
||||
სალამი
|
||||
SELECT hello, regexp_substr(hello, 'и.е') from t2;
|
||||
hello regexp_substr(hello, 'и.е')
|
||||
こんにちは
|
||||
привет
|
||||
Γεια
|
||||
სალამი
|
||||
SELECT hello, regexp_substr(hello, 'ε.α') from t2;
|
||||
hello regexp_substr(hello, 'ε.α')
|
||||
こんにちは
|
||||
привет
|
||||
Γεια
|
||||
სალამი
|
||||
SELECT hello, regexp_substr(hello, 'ა.ა') from t2;
|
||||
hello regexp_substr(hello, 'ა.ა')
|
||||
こんにちは
|
||||
привет
|
||||
Γεια
|
||||
სალამი
|
||||
SELECT hello, regexp_instr(hello, 'ん.ち') from t2;
|
||||
hello regexp_instr(hello, 'ん.ち')
|
||||
こんにちは 0
|
||||
привет 0
|
||||
Γεια 0
|
||||
სალამი 0
|
||||
SELECT hello, regexp_instr(hello, 'и.е') from t2;
|
||||
hello regexp_instr(hello, 'и.е')
|
||||
こんにちは 0
|
||||
привет 0
|
||||
Γεια 0
|
||||
სალამი 0
|
||||
SELECT hello, regexp_instr(hello, 'ε.α') from t2;
|
||||
hello regexp_instr(hello, 'ε.α')
|
||||
こんにちは 0
|
||||
привет 0
|
||||
Γεια 0
|
||||
სალამი 0
|
||||
SELECT hello, regexp_instr(hello, 'ა.ა') from t2;
|
||||
hello regexp_instr(hello, 'ა.ა')
|
||||
こんにちは 0
|
||||
привет 0
|
||||
Γεια 0
|
||||
სალამი 0
|
||||
SELECT hello, regexp_replace(hello, 'ん.ち', 'Достоевский') from t2;
|
||||
hello regexp_replace(hello, 'ん.ち', 'Достоевский')
|
||||
こんにちは こんにちは
|
||||
привет привет
|
||||
Γεια Γεια
|
||||
სალამი სალამი
|
||||
SELECT hello, regexp_replace(hello, 'и.е', 'Достоевский') from t2;
|
||||
hello regexp_replace(hello, 'и.е', 'Достоевский')
|
||||
こんにちは こんにちは
|
||||
привет привет
|
||||
Γεια Γεια
|
||||
სალამი სალამი
|
||||
SELECT hello, regexp_replace(hello, 'ε.α', 'Достоевский') from t2;
|
||||
hello regexp_replace(hello, 'ε.α', 'Достоевский')
|
||||
こんにちは こんにちは
|
||||
привет привет
|
||||
Γεια Γεια
|
||||
სალამი სალამი
|
||||
SELECT hello, regexp_replace(hello, 'ა.ა', 'Достоевский') from t2;
|
||||
hello regexp_replace(hello, 'ა.ა', 'Достоевский')
|
||||
こんにちは こんにちは
|
||||
привет привет
|
||||
Γεια Γεια
|
||||
სალამი სალამი
|
||||
DROP DATABASE mcs228_db;
|
||||
|
@ -150,6 +150,8 @@ SELECT t1_TIME, REGEXP_INSTR(t1_TIME, '22$') FROM t1 ORDER BY 1;
|
||||
SELECT t1_TIME, REGEXP_REPLACE(t1_TIME, '(59)+', 'KittyCat') FROM t1 ORDER BY 1;
|
||||
SELECT t1_TIME, REGEXP_REPLACE(t1_TIME, '22$', 'KittyCat') FROM t1 ORDER BY 1;
|
||||
|
||||
SET character_set_connection = 'utf8';
|
||||
|
||||
|
||||
CREATE TABLE t2 (hello text) engine columnstore;
|
||||
INSERT INTO t2 values('こんにちは');
|
||||
@ -177,6 +179,5 @@ SELECT hello, regexp_replace(hello, 'и.е', 'Достоевский') from t2;
|
||||
SELECT hello, regexp_replace(hello, 'ε.α', 'Достоевский') from t2;
|
||||
SELECT hello, regexp_replace(hello, 'ა.ა', 'Достоевский') from t2;
|
||||
|
||||
|
||||
# Clean UP
|
||||
DROP DATABASE mcs228_db;
|
||||
|
Reference in New Issue
Block a user