š
Many thanks guys!
Now I can insert 200 000 records in 14 seconds and Sqlite in memory was totally defeated)
08.10.2015, 13:12, "Stefan Manegold" <Stefan.Manegold@cwi.nl>:

Hi,

if you can create SQL script like

START TRANSACTION;
INSERT INTO table VALUES (1, 2, 3);
... -- n-1 more insert statements
COMMIT;

you probably can also generate a SQL script like

COPY n RECORDS INTO table FROM stdin USING DELIMITERS ',','\n';
1,2,3
... -- n-1 more data lines

That's hence bulk-loading instead of individual insert statements.

The individual insert statements incur overhead for each of them
in the entire software stack which occurs only one with the single
bulkload statement.

Best,
Stefan


----- On Oct 8, 2015, at 11:54 AM, d tikhonov d.tikhonov@revotechs.com wrote:

šThanks for fast answer.
šI understand how to solve my second question.
šBut for create insert statements I used this article



šhttps://www.monetdb.org/Documentation/Cookbooks/SQLrecipes/LoadingBulkData


š"... A much better way to do lots of inserts is to make sure the inserts are
šbundled into a single transaction. This can easily be done by surrounding the
šinserts with a START TRANSACTION and COMMIT, as in:

šSTART TRANSACTION;
šINSERT INTO table VALUES (1, 2, 3);
š...
šCOMMIT; ..."

šIs it normal that 200 000 records insert in ~1 minute?

šCan I somehow increase insert speed: disable logs or something else?
š08.10.2015, 12:24, "Sjoerd Mullender" <sjoerd@monetdb.org>:




šSee [1] for information about the different ways of getting data into
šMonetDB.
šSee [2] for information about concurrency control. Especially the
šsecond section.

š[1]
šhttps://www.monetdb.org/Documentation/Cookbooks/SQLrecipes/LoadingBulkData
š[2] https://www.monetdb.org/blog/monetdb-sql-transaction-management-scheme

šOn 08/10/15 11:00, d.tikhonov@revotechs.com wrote:



šGood day.

šI use MonetDB in my .net project via odbc driver. And I have some
šquestions, maybe you can help me.

š1. What is the best practice for inserting data via INSERT statements?

šIn MonetDB exists operation for bulk data loading (COPY INTO) but it
šrequires file or stream and this solution doesn't suit my project.

šI tried to use START TRANSACTION; ... COMMIT; but my best result was 220
š000 records in 1 minute.

šHow can I insert data via INSERT the fastest way?

š2. Does monetDB support multi thread insert, update, delete via odbc?
šWhen I tried to test it I have got ODBCException: general exception.

šHow does MonetDB handles concurrent requests?

šThanks!

š--


šBest Regards,
šDaniel Tikhonov

šProgrammer | Revotechs, LLC
šRevotechs.com
šMobile: +375 (33) 341-87-54
šEmail: d.tikhonov@revotechs.com
šSkype: revotech.d.tikhonov



š_______________________________________________
šdevelopers-list mailing list
šdevelopers-list@monetdb.org
šhttps://www.monetdb.org/mailman/listinfo/developers-list





š--
šSjoerd Mullender


š,

š_______________________________________________
šdevelopers-list mailing list
šdevelopers-list@monetdb.org
šhttps://www.monetdb.org/mailman/listinfo/developers-list
š--
šBest Regards,
šDaniel Tikhonov
šProgrammer | Revotechs, LLC
šRevotechs.com
šMobile: +375 (33) 341-87-54
šEmail: d.tikhonov@revotechs.com
šSkype: revotech.d.tikhonov

š_______________________________________________
šdevelopers-list mailing list
šdevelopers-list@monetdb.org
šhttps://www.monetdb.org/mailman/listinfo/developers-list

š

--
| Stefan.Manegold@CWI.nl | DB Architectures (DA) |
| www.CWI.nl/~manegold/ | Science Park 123 (L321) |
| +31 (0)20 592-4212 | 1098 XG Amsterdam (NL) |
_______________________________________________
developers-list mailing list
developers-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/developers-list
š
š
--š
š
š
Best Regards,
Daniel Tikhonov
š
Programmer | Revotechs, LLC
Revotechs.com
Mobile: +375 (33) 341-87-54
Email:šd.tikhonov@revotechs.com
Skype: revotech.d.tikhonov
š