提交 8a188915 authored 作者: Thomas Mueller's avatar Thomas Mueller

MySQL compatibility: support for := assignment as in @sum:=@sum+x

INSERT INTO TEST(SELECT * FROM TEST) is now supported.
上级 3606b2a5
...@@ -283,11 +283,9 @@ java org.h2.test.TestAll timer ...@@ -283,11 +283,9 @@ java org.h2.test.TestAll timer
System.setProperty("h2.check2", "true"); System.setProperty("h2.check2", "true");
/* /*
JCR: for each node type, create a table; one 'dynamic' table with parameter; JCR: for each node type, create a table; one 'dynamic' table with parameter;
option to cache the results option to cache the results
MySQL compatibility for @rownum:=@rownum+1 <link rel="icon" type="image/png" href="/path/image.png">
insert into test2 (select id, id from test);
http://blog.flexive.org/2008/12/05/porting-flexive-to-the-h2-database/ http://blog.flexive.org/2008/12/05/porting-flexive-to-the-h2-database/
postgresql generate_series? postgresql generate_series?
......
--- special grammar and test cases --------------------------------------------------------------------------------------------- --- special grammar and test cases ---------------------------------------------------------------------------------------------
select @n := case when x = 1 then 1 else @n * x end f from system_range(1, 4);
> F
> --
> 1
> 2
> 24
> 6
> rows: 4
select * from (select "x" from dual); select * from (select "x" from dual);
> exception > exception
...@@ -1910,7 +1919,7 @@ DROP TABLE TEST; ...@@ -1910,7 +1919,7 @@ DROP TABLE TEST;
create table test(id int); create table test(id int);
> ok > ok
insert into test select x from system_range(1, 100); insert into test (select x from system_range(1, 100));
> update count: 100 > update count: 100
select id/1000 from test group by id/1000; select id/1000 from test group by id/1000;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论