Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
H
h2database
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
Administrator
h2database
Commits
c5fcca01
提交
c5fcca01
authored
5月 02, 2018
作者:
Evgenij Ryazanov
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Use >> syntax in more tests
上级
67c45002
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
20 行增加
和
80 行删除
+20
-80
enum.sql
h2/src/test/org/h2/test/scripts/datatypes/enum.sql
+4
-16
time.sql
h2/src/test/org/h2/test/scripts/datatypes/time.sql
+1
-4
with.sql
h2/src/test/org/h2/test/scripts/dml/with.sql
+2
-8
range_table.sql
h2/src/test/org/h2/test/scripts/range_table.sql
+4
-16
testScript.sql
h2/src/test/org/h2/test/scripts/testScript.sql
+9
-36
没有找到文件。
h2/src/test/org/h2/test/scripts/datatypes/enum.sql
浏览文件 @
c5fcca01
...
@@ -201,37 +201,25 @@ CREATE VIEW V AS SELECT * FROM TEST;
...
@@ -201,37 +201,25 @@ CREATE VIEW V AS SELECT * FROM TEST;
>
ok
>
ok
SELECT
*
FROM
V
;
SELECT
*
FROM
V
;
>
E
>>
B
>
-
>
B
>
rows
:
1
CREATE
VIEW
V1
AS
SELECT
E
+
2
AS
E
FROM
TEST
;
CREATE
VIEW
V1
AS
SELECT
E
+
2
AS
E
FROM
TEST
;
>
ok
>
ok
SELECT
*
FROM
V1
;
SELECT
*
FROM
V1
;
>
E
>>
3
>
-
>
3
>
rows
:
1
CREATE
VIEW
V2
AS
SELECT
E
+
E
AS
E
FROM
TEST
;
CREATE
VIEW
V2
AS
SELECT
E
+
E
AS
E
FROM
TEST
;
>
ok
>
ok
SELECT
*
FROM
V2
;
SELECT
*
FROM
V2
;
>
E
>>
2
>
-
>
2
>
rows
:
1
CREATE
VIEW
V3
AS
SELECT
-
E
AS
E
FROM
TEST
;
CREATE
VIEW
V3
AS
SELECT
-
E
AS
E
FROM
TEST
;
>
ok
>
ok
SELECT
*
FROM
V3
;
SELECT
*
FROM
V3
;
>
E
>>
-
1
>
--
>
-
1
>
rows
:
1
SELECT
*
FROM
INFORMATION_SCHEMA
.
COLUMNS
WHERE
COLUMN_NAME
=
'E'
ORDER
BY
TABLE_NAME
;
SELECT
*
FROM
INFORMATION_SCHEMA
.
COLUMNS
WHERE
COLUMN_NAME
=
'E'
ORDER
BY
TABLE_NAME
;
>
TABLE_CATALOG
TABLE_SCHEMA
TABLE_NAME
COLUMN_NAME
ORDINAL_POSITION
COLUMN_DEFAULT
IS_NULLABLE
DATA_TYPE
CHARACTER_MAXIMUM_LENGTH
CHARACTER_OCTET_LENGTH
NUMERIC_PRECISION
NUMERIC_PRECISION_RADIX
NUMERIC_SCALE
CHARACTER_SET_NAME
COLLATION_NAME
TYPE_NAME
NULLABLE
IS_COMPUTED
SELECTIVITY
CHECK_CONSTRAINT
SEQUENCE_NAME
REMARKS
SOURCE_DATA_TYPE
COLUMN_TYPE
COLUMN_ON_UPDATE
>
TABLE_CATALOG
TABLE_SCHEMA
TABLE_NAME
COLUMN_NAME
ORDINAL_POSITION
COLUMN_DEFAULT
IS_NULLABLE
DATA_TYPE
CHARACTER_MAXIMUM_LENGTH
CHARACTER_OCTET_LENGTH
NUMERIC_PRECISION
NUMERIC_PRECISION_RADIX
NUMERIC_SCALE
CHARACTER_SET_NAME
COLLATION_NAME
TYPE_NAME
NULLABLE
IS_COMPUTED
SELECTIVITY
CHECK_CONSTRAINT
SEQUENCE_NAME
REMARKS
SOURCE_DATA_TYPE
COLUMN_TYPE
COLUMN_ON_UPDATE
...
...
h2/src/test/org/h2/test/scripts/datatypes/time.sql
浏览文件 @
c5fcca01
...
@@ -50,10 +50,7 @@ INSERT INTO TEST VALUES (TIME '08:00:00');
...
@@ -50,10 +50,7 @@ INSERT INTO TEST VALUES (TIME '08:00:00');
>
update
count
:
1
>
update
count
:
1
SELECT
TIME
FROM
TEST
;
SELECT
TIME
FROM
TEST
;
>
TIME
>>
08
:
00
:
00
>
--------
>
08
:
00
:
00
>
rows
:
1
DROP
TABLE
TEST
;
DROP
TABLE
TEST
;
>
ok
>
ok
...
...
h2/src/test/org/h2/test/scripts/dml/with.sql
浏览文件 @
c5fcca01
...
@@ -14,10 +14,7 @@ select sum(n) from (
...
@@ -14,10 +14,7 @@ select sum(n) from (
)
)
select
n
from
r
select
n
from
r
);
);
>
SUM
(
N
)
>>
6
>
------
>
6
>
rows
:
1
select
sum
(
n
)
from
(
select
0
)
join
(
select
sum
(
n
)
from
(
select
0
)
join
(
with
recursive
r
(
n
)
as
(
with
recursive
r
(
n
)
as
(
...
@@ -25,10 +22,7 @@ select sum(n) from (select 0) join (
...
@@ -25,10 +22,7 @@ select sum(n) from (select 0) join (
)
)
select
n
from
r
select
n
from
r
)
on
1
=
1
;
)
on
1
=
1
;
>
SUM
(
N
)
>>
6
>
------
>
6
>
rows
:
1
select
0
from
(
select
0
from
(
select
0
where
0
in
(
select
0
where
0
in
(
...
...
h2/src/test/org/h2/test/scripts/range_table.sql
浏览文件 @
c5fcca01
...
@@ -23,16 +23,10 @@ EXPLAIN PLAN FOR SELECT * FROM SYSTEM_RANGE(1, 20);
...
@@ -23,16 +23,10 @@ EXPLAIN PLAN FOR SELECT * FROM SYSTEM_RANGE(1, 20);
select
sum
(
x
)
from
system_range
(
2
,
1000
)
r
where
select
sum
(
x
)
from
system_range
(
2
,
1000
)
r
where
not
exists
(
select
*
from
system_range
(
2
,
32
)
r2
where
r
.
x
>
r2
.
x
and
mod
(
r
.
x
,
r2
.
x
)
=
0
);
not
exists
(
select
*
from
system_range
(
2
,
32
)
r2
where
r
.
x
>
r2
.
x
and
mod
(
r
.
x
,
r2
.
x
)
=
0
);
>
SUM
(
X
)
>>
76127
>
------
>
76127
>
rows
:
1
SELECT
COUNT
(
*
)
FROM
SYSTEM_RANGE
(
0
,
2111222333
);
SELECT
COUNT
(
*
)
FROM
SYSTEM_RANGE
(
0
,
2111222333
);
>
COUNT
(
*
)
>>
2111222334
>
----------
>
2111222334
>
rows
:
1
select
*
from
system_range
(
2
,
100
)
r
where
select
*
from
system_range
(
2
,
100
)
r
where
not
exists
(
select
*
from
system_range
(
2
,
11
)
r2
where
r
.
x
>
r2
.
x
and
mod
(
r
.
x
,
r2
.
x
)
=
0
);
not
exists
(
select
*
from
system_range
(
2
,
11
)
r2
where
r
.
x
>
r2
.
x
and
mod
(
r
.
x
,
r2
.
x
)
=
0
);
...
@@ -136,19 +130,13 @@ SELECT COUNT(*) FROM SYSTEM_RANGE(10, 2, -2);
...
@@ -136,19 +130,13 @@ SELECT COUNT(*) FROM SYSTEM_RANGE(10, 2, -2);
>>
5
>>
5
SELECT
*
FROM
SYSTEM_RANGE
(
1
,
1
);
SELECT
*
FROM
SYSTEM_RANGE
(
1
,
1
);
>
X
>>
1
>
-
>
1
>
rows
:
1
SELECT
COUNT
(
*
)
FROM
SYSTEM_RANGE
(
1
,
1
);
SELECT
COUNT
(
*
)
FROM
SYSTEM_RANGE
(
1
,
1
);
>>
1
>>
1
SELECT
*
FROM
SYSTEM_RANGE
(
1
,
1
,
-
1
);
SELECT
*
FROM
SYSTEM_RANGE
(
1
,
1
,
-
1
);
>
X
>>
1
>
-
>
1
>
rows
:
1
SELECT
COUNT
(
*
)
FROM
SYSTEM_RANGE
(
1
,
1
,
-
1
);
SELECT
COUNT
(
*
)
FROM
SYSTEM_RANGE
(
1
,
1
,
-
1
);
>>
1
>>
1
...
...
h2/src/test/org/h2/test/scripts/testScript.sql
浏览文件 @
c5fcca01
...
@@ -7173,10 +7173,7 @@ CALL NEXT VALUE FOR TEST_LONG;
...
@@ -7173,10 +7173,7 @@ CALL NEXT VALUE FOR TEST_LONG;
>
rows
:
1
>
rows
:
1
CALL
IDENTITY
();
CALL
IDENTITY
();
>
IDENTITY
()
>>
90123456789012345
>
-----------------
>
90123456789012345
>
rows
:
1
SELECT
SEQUENCE_NAME
,
CURRENT_VALUE
,
INCREMENT
FROM
INFORMATION_SCHEMA
.
SEQUENCES
;
SELECT
SEQUENCE_NAME
,
CURRENT_VALUE
,
INCREMENT
FROM
INFORMATION_SCHEMA
.
SEQUENCES
;
>
SEQUENCE_NAME
CURRENT_VALUE
INCREMENT
>
SEQUENCE_NAME
CURRENT_VALUE
INCREMENT
...
@@ -7825,28 +7822,19 @@ insert into test(name) values('World');
...
@@ -7825,28 +7822,19 @@ insert into test(name) values('World');
>
update
count
:
1
>
update
count
:
1
call
identity
();
call
identity
();
>
IDENTITY
()
>>
2
>
----------
>
2
>
rows
:
1
insert
into
test
(
id
,
name
)
values
(
1234567890123456
,
'World'
);
insert
into
test
(
id
,
name
)
values
(
1234567890123456
,
'World'
);
>
update
count
:
1
>
update
count
:
1
call
identity
();
call
identity
();
>
IDENTITY
()
>>
1234567890123456
>
----------------
>
1234567890123456
>
rows
:
1
insert
into
test
(
name
)
values
(
'World'
);
insert
into
test
(
name
)
values
(
'World'
);
>
update
count
:
1
>
update
count
:
1
call
identity
();
call
identity
();
>
IDENTITY
()
>>
1234567890123457
>
----------------
>
1234567890123457
>
rows
:
1
select
*
from
test
order
by
id
;
select
*
from
test
order
by
id
;
>
ID
NAME
>
ID
NAME
...
@@ -7876,28 +7864,19 @@ insert into test(name) values('World');
...
@@ -7876,28 +7864,19 @@ insert into test(name) values('World');
>
update
count
:
1
>
update
count
:
1
call
identity
();
call
identity
();
>
IDENTITY
()
>>
2
>
----------
>
2
>
rows
:
1
insert
into
test
(
id
,
name
)
values
(
1234567890123456
,
'World'
);
insert
into
test
(
id
,
name
)
values
(
1234567890123456
,
'World'
);
>
update
count
:
1
>
update
count
:
1
call
identity
();
call
identity
();
>
IDENTITY
()
>>
1234567890123456
>
----------------
>
1234567890123456
>
rows
:
1
insert
into
test
(
name
)
values
(
'World'
);
insert
into
test
(
name
)
values
(
'World'
);
>
update
count
:
1
>
update
count
:
1
call
identity
();
call
identity
();
>
IDENTITY
()
>>
1234567890123457
>
----------------
>
1234567890123457
>
rows
:
1
select
*
from
test
order
by
id
;
select
*
from
test
order
by
id
;
>
ID
NAME
>
ID
NAME
...
@@ -7997,10 +7976,7 @@ insert into x(id) values(1);
...
@@ -7997,10 +7976,7 @@ insert into x(id) values(1);
>
update
count
:
1
>
update
count
:
1
select
b
from
x
;
select
b
from
x
;
>
B
>>
a
>
-
>
a
>
rows
:
1
delete
from
x
;
delete
from
x
;
>
update
count
:
1
>
update
count
:
1
...
@@ -8030,10 +8006,7 @@ insert into x(id) values(1);
...
@@ -8030,10 +8006,7 @@ insert into x(id) values(1);
>
update
count
:
1
>
update
count
:
1
select
b
from
x
;
select
b
from
x
;
>
B
>>
null
>
----
>
null
>
rows
:
1
delete
from
x
;
delete
from
x
;
>
update
count
:
1
>
update
count
:
1
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论