 |
|
 |
|
Next: how to insert file to SQL server using VB
|
| Author |
Message |
External

Since: Jan 15, 2008 Posts: 5
|
(Msg. 1) Posted: Fri Oct 24, 2008 1:25 am
Post subject: [Info-Ingres] Generate 1 million rows of unique data - Friday fun Archived from groups: comp>databases>ingres (more info?)
|
|
|
Hi everyone,
I was recently trading techno nerdy stories with my children and their
friends who have, it seems, surpassed my own skills. A challenge was issued
to see which programmer could create a million unique rows in the database
the most quickly. (They were all talk no action of course ) The tools were
PHP, C++, vb, OpenROAD, mysql, ingres, mssql, Compiled code vs interpreted,
FOR loops vs WHILE loops etc.
This was my offering, standard ingres SQL and trusty terminal monitor.
select date('now');\g
create table digits (v varchar(1));\g
create table millions (v1 varchar(6)) ;\g
commit;\g
insert into digits values ('0');
insert into digits values ('1');
insert into digits values ('2');
insert into digits values ('3');
insert into digits values ('4');
insert into digits values ('5');
insert into digits values ('6');
insert into digits values ('7');
insert into digits values ('8');
insert into digits values ('9');
commit;\g
insert into millions
select a.v + b.v + c.v + d.v + e.v + f.v
from digits a, digits b, digits c, digits d, digits e, digits f;\g
commit;\g
select date('now');\g
Timings here for your interest.
The physical table generated was around 11Mb.
And I found it interesting that the 1GB transaction log filled to 37%
I guess I was expecting of the order of 6Mb
Linux almost won but ran out of transaction log.
SunFire V880 Sparc V9 8x1.2Ghz processors 32GB RAM
Storedge 3510 with Raid 0+1, dual transaction logs of 1GB
DB cache of about 60MB RAM
rows seconds
1000 0
10000 3
100000 22
1000000 230
2. SunFire V880 Sparc V9 6x750Mhz processors 12GB RAM
Storedge 3310 with RAID 0+1, dual transaction logs of 1GB
DB Cache around 30MB ram
rows seconds
1000 1
10000 4
100000 37
1000000 344
3. Linux Single 2.2 Ghz Xeon dualcore processor 2GB RAM
Internal disks RAID 0, Single transaction log of 500Mb
DB Cache around 60 MB RAM
rows seconds
1000 0
10000 1
100000 6
1000000 txn log full aborted
I will increase the log size later this weekend and try again. >> Stay informed about: [Info-Ingres] Generate 1 million rows of unique data - Fri.. |
|
| Back to top |
|
 |  |
External

Since: Oct 14, 2008 Posts: 4
|
(Msg. 2) Posted: Fri Oct 24, 2008 1:25 am
Post subject: Re: Generate 1 million rows of unique data - Friday fun [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
Hm, this is much faster on my Linux desktop (9.1.1 a64.lnx), 62
seconds for 100000 rows.
However, I would slightly change your idea to eliminate the logging
system, i.e.
----
select date('now');\p\g
create table digits (v varchar(1));\p\g
commit;\p\g
insert into digits values ('0');
insert into digits values ('1');
insert into digits values ('2');
insert into digits values ('3');
insert into digits values ('4');
insert into digits values ('5');
insert into digits values ('6');
insert into digits values ('7');
insert into digits values ('8');
insert into digits values ('9');
commit;\p\g
create table millions as
select a.v + b.v + c.v + d.v + e.v + f.v as v1
from digits a, digits b, digits c, digits d, digits e, digits f
with nojournaling;\p\g
commit;\p\g
select date('now');\p\g
----
The create table ... as select ... with nojournaling makes sure that
the insert doesn't go through the logging system, got the 1000000 rows
in 2 seconds.
Regards
Kristoff
On Oct 24, 7:11 am, "Paul White" wrote:
> Hi everyone,
>
> I was recently trading techno nerdy stories with my children and their
> friends who have, it seems, surpassed my own skills. A challenge was issued
> to see which programmer could create a million unique rows in the database
> the most quickly. (They were all talk no action of course ) The tools were
> PHP, C++, vb, OpenROAD, mysql, ingres, mssql, Compiled code vs interpreted,
> FOR loops vs WHILE loops etc.
>
> This was my offering, standard ingres SQL and trusty terminal monitor.
>
> select date('now');\g
>
> create table digits (v varchar(1));\g
> create table millions (v1 varchar(6)) ;\g
> commit;\g
>
> insert into digits values ('0');
> insert into digits values ('1');
> insert into digits values ('2');
> insert into digits values ('3');
> insert into digits values ('4');
> insert into digits values ('5');
> insert into digits values ('6');
> insert into digits values ('7');
> insert into digits values ('8');
> insert into digits values ('9');
> commit;\g
>
> insert into millions
> select a.v + b.v + c.v + d.v + e.v + f.v
> from digits a, digits b, digits c, digits d, digits e, digits f;\g
> commit;\g
>
> select date('now');\g
>
> Timings here for your interest.
> The physical table generated was around 11Mb.
> And I found it interesting that the 1GB transaction log filled to 37%
> I guess I was expecting of the order of 6Mb
> Linux almost won but ran out of transaction log.
>
> SunFire V880 Sparc V9 8x1.2Ghz processors 32GB RAM
> Storedge 3510 with Raid 0+1, dual transaction logs of 1GB
> DB cache of about 60MB RAM
>
> rows seconds
> 1000 0
> 10000 3
> 100000 22
> 1000000 230
>
> 2. SunFire V880 Sparc V9 6x750Mhz processors 12GB RAM
> Storedge 3310 with RAID 0+1, dual transaction logs of 1GB
> DB Cache around 30MB ram
>
> rows seconds
> 1000 1
> 10000 4
> 100000 37
> 1000000 344
>
> 3. Linux Single 2.2 Ghz Xeon dualcore processor 2GB RAM
> Internal disks RAID 0, Single transaction log of 500Mb
> DB Cache around 60 MB RAM
>
> rows seconds
> 1000 0
> 10000 1
> 100000 6
> 1000000 txn log full aborted
>
> I will increase the log size later this weekend and try again. >> Stay informed about: [Info-Ingres] Generate 1 million rows of unique data - Fri.. |
|
| Back to top |
|
 |  |
External

Since: Oct 24, 2008 Posts: 1
|
(Msg. 3) Posted: Fri Oct 24, 2008 7:25 am
Post subject: Re: [Info-Ingres] Generate 1 million rows of unique data - Fridayfun [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
Hi Paul,
I ran it on a Box with:
Ingres II 9.1.1 (a64.lnx/103)NPTL
1GB Transaction Log
55MB DMF Cache
RedHat ES5 Linux
SunFire x4100 8GB RAM 2 x Dual Core CPU 2.8Ghz Storedge 6140 RAID 10
1000000 rows in 5 sec.
Leandro Fava
Setor de Informática - UNISC
+55 51 3717 7636
On Oct 24, 7:11 am, "Paul White" wrote:
> Hi everyone,
>
> I was recently trading techno nerdy stories with my children and their
> friends who have, it seems, surpassed my own skills. A challenge was issued
> to see which programmer could create a million unique rows in the database
> the most quickly. (They were all talk no action of course ) The tools were
> PHP, C++, vb, OpenROAD, mysql, ingres, mssql, Compiled code vs interpreted,
> FOR loops vs WHILE loops etc.
>
> This was my offering, standard ingres SQL and trusty terminal monitor.
>
> select date('now');\g
>
> create table digits (v varchar(1));\g
> create table millions (v1 varchar(6)) ;\g
> commit;\g
>
> insert into digits values ('0');
> insert into digits values ('1');
> insert into digits values ('2');
> insert into digits values ('3');
> insert into digits values ('4');
> insert into digits values ('5');
> insert into digits values ('6');
> insert into digits values ('7');
> insert into digits values ('8');
> insert into digits values ('9');
> commit;\g
>
> insert into millions
> select a.v + b.v + c.v + d.v + e.v + f.v
> from digits a, digits b, digits c, digits d, digits e, digits f;\g
> commit;\g
>
> select date('now');\g
>
> Timings here for your interest.
> The physical table generated was around 11Mb.
> And I found it interesting that the 1GB transaction log filled to 37%
> I guess I was expecting of the order of 6Mb
> Linux almost won but ran out of transaction log.
>
> SunFire V880 Sparc V9 8x1.2Ghz processors 32GB RAM
> Storedge 3510 with Raid 0+1, dual transaction logs of 1GB
> DB cache of about 60MB RAM
>
> rows seconds
> 1000 0
> 10000 3
> 100000 22
> 1000000 230
>
> 2. SunFire V880 Sparc V9 6x750Mhz processors 12GB RAM
> Storedge 3310 with RAID 0+1, dual transaction logs of 1GB
> DB Cache around 30MB ram
>
> rows seconds
> 1000 1
> 10000 4
> 100000 37
> 1000000 344
>
> 3. Linux Single 2.2 Ghz Xeon dualcore processor 2GB RAM
> Internal disks RAID 0, Single transaction log of 500Mb
> DB Cache around 60 MB RAM
>
> rows seconds
> 1000 0
> 10000 1
> 100000 6
> 1000000 txn log full aborted
>
> I will increase the log size later this weekend and try again.
_______________________________________________
Info-Ingres mailing list
Info-Ingres.DeleteThis@kettleriverconsulting.com
http://www.kettleriverconsulting.com/mailman/listinfo/info-ingres >> Stay informed about: [Info-Ingres] Generate 1 million rows of unique data - Fri.. |
|
| Back to top |
|
 |  |
| Related Topics: | [Info-Ingres] Upgrade from Ingres 2.6 SP5 to Ingres 2006 r2 - Hi: I am testing the upgrade process from Ingres 2.6 sp2 over tru64 5.1b to Ingres 2006 r2 (installing Ingres 2006 r2 directly over 2.6 installation) I have an error trying to startup ingres before upgradedb command. The error:..
[Info-Ingres] FW: VIP Webinar - The Ingres Source Architec.. - If you missed the first presentation the next one starts in under an hour. Colombo (Sri Lanka) Thursday, 17 January 2008 at 6:30:00 AM Brisbane (Australia - Queensland) Thursday, 17 January 2008 at 11:00:00 AM Los Angeles (U.S.A. - California) Wednesday...
[Info-Ingres] FW: Ingres ODBC Driver Support REPETED ? - Hello Thiago, The Ingres ODBC driver does not support repeated queries at the present time. I recommend instead using SQLPrepare() and SQLExecute(), as these provide even better improvements in performance than repeated queries. I'm not sure what an....
[Info-Ingres] Grails struggles with Ingres JDBC Driver .... - Gang, I've been able to fully utilize the Grails framework with Ingres, but I've had to "resort" to using Kettle River's JDBC driver (the former Caribou Lake JDBC driver). Unfortunately, Grails fails if I try to use the latest Ingres JDBC dri...
[Info-Ingres] Ingres 2.6 on Linux with internal threads - Hi, I'm still trying to get Ingres 2.6 to run well on Linux. My problem is our Linux installation is SuSe10 with NPTL and Ingres 2.6 is uses LinuxThreads. I recently learned that SuSe10 removed the Linuxthread libraries so using LD_ASSUME_KERNEL=2.4.1.... |
|
You can post new topics in this forum You can reply to topics in this forum You can edit your posts in this forum You can delete your posts in this forum You can vote in polls in this forum
|
|
|
|
 |
|
|