59 lines
1.1 KiB
Plaintext
59 lines
1.1 KiB
Plaintext
create schema xtest;
|
|
RUN use xtest
|
|
|
|
0 rows affected
|
|
RUN create table mytable (id int primary key, name varchar(40), price decimal(5,2), info json)
|
|
|
|
0 rows affected
|
|
RUN insert into mytable values (1, 'banana', 1.20, '{"color": "yellow"}')
|
|
|
|
1 rows affected
|
|
RUN insert into mytable values (2, 'apple', 0.25, '{"color":"red"}')
|
|
|
|
1 rows affected
|
|
RUN insert into mytable values (3, 'tomato', 1.80, '{"color":"red"}')
|
|
|
|
1 rows affected
|
|
RUN insert into mytable values (4, 'mango', 3.14, '{"color":"green"}')
|
|
|
|
1 rows affected
|
|
RUN insert into mytable values (5, 'orange', 0.90, '{"color":"orange"}')
|
|
|
|
1 rows affected
|
|
send Mysqlx.Crud.Delete {
|
|
collection {
|
|
name: "mytable"
|
|
schema: "xtest"
|
|
}
|
|
data_model: TABLE
|
|
criteria {
|
|
type: OPERATOR
|
|
operator {
|
|
name: "=="
|
|
param {
|
|
type: IDENT
|
|
identifier {
|
|
name: "name"
|
|
}
|
|
}
|
|
param {
|
|
type: LITERAL
|
|
literal {
|
|
type: V_OCTETS
|
|
v_octets {
|
|
value: "banana"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
1 rows affected
|
|
Mysqlx.Ok {
|
|
msg: "bye!"
|
|
}
|
|
ok
|
|
drop schema if exists xtest;
|