~drizzle-trunk/drizzle/development

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
create table t1 (a int primary key auto_increment, b varchar(100));
select http_post("http://localhost:PORT/0.1/sql", 'select * from t1;');;
http_post("http://localhost:PORT/0.1/sql", 'select * from t1;')
{
   "query" : "select * from t1;",
   "result_set" : [
      [ "", "" ]
   ],
   "sqlstate" : "00000"
}

insert into t1 (b) values ("from MySQL protocol");
select http_post('http://localhost:PORT/0.1/sql', 'select * from t1;');;
http_post('http://localhost:PORT/0.1/sql', 'select * from t1;')
{
   "query" : "select * from t1;",
   "result_set" : [
      [ "1", "from MySQL protocol" ],
      [ "", "" ]
   ],
   "sqlstate" : "00000"
}

select http_post('http://localhost:PORT/0.1/sql', 'insert into t1 (b) values (\'from http\');');;
http_post('http://localhost:PORT/0.1/sql', 'insert into t1 (b) values (\'from http\');')
{
   "query" : "insert into t1 (b) values ('from http');",
   "sqlstate" : "00000"
}

SELECT * from t1;
a	b
1	from MySQL protocol
2	from http
drop table t1;