Files
MaxScale/maxscale-system-test/masking/masking_mysqltest/r/masking_column.result
Timofey Turenko 9737ffe092 Fix masking tests
The masking filter now has a default fill value, so that if a
provided value does not match, then "X" is used.

The tests were modified to use "Y" as an explicitly provided
fill value (to distinguish from the default "X") and the results
were the default fill value would kick in were modified accordingly.
2017-06-26 12:22:39 +02:00

58 lines
1.8 KiB
Plaintext

drop database if exists maskingdb;
create database maskingdb;
use maskingdb;
create table masking (a TEXT, x TEXT, y TEXT);
insert into masking values ("hello", "hello", "hello");
insert into masking values (NULL, "hello", "hello");
insert into masking values ("hello", NULL, "hello");
insert into masking values ("hello", "hello", NULL);
insert into masking values (NULL, NULL, "hello");
insert into masking values ("hello", NULL, NULL);
insert into masking values (NULL, NULL, NULL);
select * from masking;
a x y
YYYYY hello hello
NULL hello hello
YYYYY NULL hello
YYYYY hello NULL
NULL NULL hello
YYYYY NULL NULL
NULL NULL NULL
drop table masking;
create table masking (x TEXT, a TEXT, y TEXT);
insert into masking values ("hello", "hello", "hello");
insert into masking values (NULL, "hello", "hello");
insert into masking values ("hello", NULL, "hello");
insert into masking values ("hello", "hello", NULL);
insert into masking values (NULL, NULL, "hello");
insert into masking values ("hello", NULL, NULL);
insert into masking values (NULL, NULL, NULL);
select * from masking;
x a y
hello YYYYY hello
NULL YYYYY hello
hello NULL hello
hello YYYYY NULL
NULL NULL hello
hello NULL NULL
NULL NULL NULL
drop table masking;
create table masking (x TEXT, y TEXT, a TEXT);
insert into masking values ("hello", "hello", "hello");
insert into masking values (NULL, "hello", "hello");
insert into masking values ("hello", NULL, "hello");
insert into masking values ("hello", "hello", NULL);
insert into masking values (NULL, NULL, "hello");
insert into masking values ("hello", NULL, NULL);
insert into masking values (NULL, NULL, NULL);
select * from masking;
x y a
hello hello YYYYY
NULL hello YYYYY
hello NULL YYYYY
hello hello NULL
NULL NULL YYYYY
hello NULL NULL
NULL NULL NULL
drop table masking;