|
pkmonster 发表于 2012-7-14 15:55 ![]()
在dm7上对比了这个简单函数, 发现比PostgreSQL快了15倍。
dm7不如xugu快
Please input server URL:localhost
Please input server port:5138
Please input database name:SYSTEM
please input user name:SYSDBA
please input password:SYSDBA
Connect ok.
SQL> create function f1(x integer) return integer as
2 begin
3 if x <= 2 then
4 return 1;
5 end if;
6 return f1(x - 1) + f1(x - 2);
7 end;
Use time:125 ms.
ok.
SQL>
SQL> select f1(30);
Use time:437 ms.
EXPR1(INTEGER) |
-------------------------------------L1-------------------------------------
832040 |
Total 1 records.
SQL>
SQL> select f1(30);
Use time:390 ms.
EXPR1(INTEGER) |
-------------------------------------L1-------------------------------------
832040 |
Total 1 records.
~~~~~~~~~~~~~~~~~~~~~
C:\dmdbms\bin>disql tpch/tpch
服务器[LOCALHOST:5236]:处于普通打开状态
使用普通用户登录
登录使用时间 :16.671(ms)
disql V7.1.1.180-Build(2012.07.25-21440trunc)
SQL>create function f1(x integer) return integer as
2 begin
3 if x <= 2 then
4 return 1;
5 end if;
6 return f1(x - 1) + f1(x - 2);
7 end;
8
9 /
操作已执行
已用时间: 149.264(ms) clock tick:0. Execute id is 8.
SQL>select f1(30);
行号 f1(30)
---------- ----------
1 832040
已用时间: 788.233(ms) clock tick:0. Execute id is 9.
SQL>select f1(30);
行号 f1(30)
---------- ----------
1 832040
已用时间: 795.277(ms) clock tick:0. Execute id is 10.
|
|