Hi @ll! First of all: Sorry for my bad english. I'm working on a C# project. For the data storage I use a SQLite DB. Everything works well...

How It Works

Get an answer in three easy steps. Here's how it works...

Ask Your Question

1. Ask Your Question

Enter your SQLite question at the top of this page and click Get An Answer.

Pick Your Priority

2. Pick Your Priority

Tell us how quickly you want your SQLite question answered.

Get An Answer

3. Get An Answer

Connect with your programmer via online chat or telephone call.

Answer

Customer
Hi @ll! First of all: Sorry for my bad english. I'm working on a C# project. For the data storage I use a SQLite DB. Everything works well except the speed of parsing the data (lots of data) from a XML file into the SQLite DB. The Problem is, that I have to make an INSERT for every row of data. I made the same projekt with a mySQL Database where I had the same problem with the speed. To make it faster I joind the INSERT into one INSERT like this: [php]INSERT INTO database.table (Time, P_ID, Type, Value) VALUES (Time, P_ID, Type, Value), (Time, P_ID, Type, Value) VALUES (Time, P_ID, Type, Value), (Time, P_ID, Type, Value) VALUES (Time, P_ID, Type, Value), (Time, P_ID, Type, Value) VALUES (Time, P_ID, Type, Value) [...][/php] When I tried to do the same with the SQLite I get an Error. Now my question: Is it possible to join some INSERTs into one INSERT like it is possible in mySQL? :huh: Thank you for your answers. Best wishes Tha Banana
Last updated
Customer
I've found an answer. It's easy, when you know how it works: INSERT INTO 'tablename' ('column1', 'column2') VALUES ('data1', 'data2'), ('data3', 'data4'), ('data5', 'data6'), ('data7', 'data8'); can be recast into sqlite as: INSERT INTO 'tablename' SELECT 'data1' AS 'column1', 'data2' AS 'column2' UNION SELECT 'data3', 'data4' UNION SELECT 'data5', 'data6' UNION SELECT 'data7', 'data8' Found at: http://stackoverflow.com/questions/1609637/is-it-possible-to-insert-multiple-rows-at-a-time-in-an-sqlite-database The Banana
Posted

quoteTestimonialsquote

About ExpertHelp

ExpertHelp is changing the way you connect with service professionals.

Whether you have a quick question while preparing your taxes, troubleshooting a computer problem, or need to hire an attorney, ExpertHelp is the most convenient and affordable way to connect with the right service professional to get the job done.

ExpertHelp has been in business since 2011, is an A+ Rated Better Business Bureau accredited member, and offers a 100% satisfaction guarantee on every question you ask!

More SQLite Questions...

Ask Your SQLite Question & Get An Answer Now!