Share My Creation Csv to SQLite program - klaus Apr 24, 2023 (42 reactions) I left also the previous version zip file.
EDIT: 2021.09.18
Added the use of SQLite transaction, suggested by Diceman in post #6.
EDIT: 2021.01.29
Added an exe file:
CsvToSQLiteExe.zip
You need to unzip it to get the exe file.
Unfortunately the exe file is not accepted by my McAfee anti virus prog B4A Question SQL operations in service, with transaction. The result: database is locked (code 5) - Jeffrey Cameron (first post) Jul 09, 2024 (1 reaction) Sqlite isn't designed to be a multi-user/thread database. You might try moving your begin transaction statement down to where you actually start writing and see if that helps.
To avoid issues like this I generally I have a single SqliteManager class that handles all of the I/O requests sequential B4A Tutorial SQL tutorial - Erel Oct 02, 2019 (20 reactions) The above code took less than half a second to run on a real device.
Without the BeginTransaction / EndTransaction block it took about 70 seconds.
A transaction block can also be used to guarantee that a set of changes were successfully done. Either all changes are made or none are made.
By calling B4A Question SQLite remove duplicate records.[SOLVED TWICE] - Roger Daley (first post) Oct 13, 2019 (3 reactions) rraswisak
Many thanks for your working example. For me it was a great tutorial on SQL and I was correct, my first attempts to use your suggestions screwed up the syntax. Working examples are the best teachers, I now have a little bit better understanding of SQL although I don't know what/why the B4J Question Reading in large amounts of data in DB - PCastagnetti (first post) Jun 28, 2017 (2 reactions) Did you use the transactions?
The use of transactions increases performance (in sqlite DB).
SQL.BeginTransaction
''Start insert loop
SQL.ExecNonQuery("your insert into.....")
''End insert loop
SQL.TransactionSuccessful B4J Question SQLite Transaction - Erel (first post) Jan 23, 2019 (1 reaction) If you only need to make a single change then you can let the SQL engine start and close the transaction for you. In this case there is no reason not to include all of them in a single transaction (though your code is also fine). B4A Question sqLite Database PRAGMA wal_checkpoint(TRUNCATE) fails - Erel (first post) Sep 06, 2020 (1 reaction) Sounds to me that you are making things much more complicated than they need to be.
Why it is important?
SQL.TransactionSuccessful commits the transaction.
The project is too large for me to help you. If you think that there is an issue then create small project that demonstrates it. Do remember B4A Question SQLite: preventing multiple calls to BeginTransaction - Mahares (first post) May 23, 2021 (1 reaction) What about: sql.AddNonQueryToBatch(. FIrst result in this search:
https://www.b4x./?query=AddNonQueryToBatch
It has a built in begin/end transaction. After you first click the Button, immediately have: btn.enable =false, then when the transaction is successful and complete. enable the button: btn.e Share My Creation Financial Mobile App (SQLite) - Abdull Cadre Jul 24, 2024 (9 reactions) Financial Mobile App 155624 Just $10.9 - Paypal: abdullcadre@gmail.com Financial Mobile App is a mobile application developed in B4X for Android that allows users to create and manage financial cards. With this app, users can create cards, manage transactions, and customize profile settings and cur B4A Question SQLite Cannot Save Changes - Computersmith64 (first post) Apr 17, 2017 (2 reactions) Also - I notice you are doing a sql.BeginTransaction But there is no corresponding TransactionSuccessful or EndTransaction. You don't need to run a transaction on a single SELECT query anyway & I don't even know if it would work - but if it does, then your SELECT will fail because you haven't go Page: 1 2 3 4 5 6 7 Powered by ColBERT |