Subject Re: [ib-support] Re: Writing data in tables!
Author Olivier Mascia
Simon,

Art Metz <ametz@...> has written excellent recommandations about this
issue. Let me just give you some words more specifically about IBPP.

With IBPP, you'd write something roughly this way (pseudo-code) and this
would be pretty much the template of your IB-API solution :

tr->Start();
st->Prepare("INSERT INTO TBL(CL1, CL2, CL3, CL4) VALUES(?, ?, ?, ?)");
...
// Looping 15000 times
st->Set(1, value1);
st->Set(2, value2);
st->Set(3, value3);
st->Set(4, value4);
st->Execute();
...
// And when done your 15000 items set,
tr->Commit();

I am sure the net speed will depend on environmental factors more than on
the code.

The code readily available through www.ibpp.org is not up to date. The
package exposed to be downloaded is months old. And due to few people
participating at this time and so much enhancement in progress, even the
CVS code is not up to date, though should be within the next two weeks. I
can speak about it : I am the one to blame for that. I'm sending you a
small zip by private email with the very latest code. The problem : the
documentation. But I can help you on that if you want.

Olivier Mascia

--On lundi 29 janvier 2001 18:07 +0000 simpor81@... wrote:

> Well I have tried to use ibobjects and it's going to slow. And the
> C++ code that you can get on www.ibpp.org doesn't seem to work for
> me, so I tried to take a try for my self and it doesn't work at all.
>
> In my program does I heva to write 15000 post to tables, the primary
> goal is that this will take just a sec. Now it's taking (with
> ibobjects) around 2 min. So I did think that using Interbase API
> directly would make this a little bit faster.
>
> In my database I have a table that looks pretty much like the
> DEPARTMENT table in employee.gdb, it's in a table like that, that I
> would like to write 15000 posts.
>
> Is there any other way to read very fast to Interbase???
>
> Simon