[android-developers] Database transaction help needed.

2010-08-24 Thread tatebn
I'm using transactions to insert data into several tables with foreign key relationships. Basically I have a wrapper for each table. Each wrapper creates it's own SQLiteOpenHelper and holds onto the SQLiteDatabase that comes from the getWriteableDatabase() call. Now here's the problem, When I

Re: [android-developers] Database transaction help needed.

2010-08-24 Thread Kim Damevin
Hi, Do you call getWriteableDatabase twice ? because you shouldn't. It should be the same SQLiteDatabase object or you have to end the transaction from the first one before you start a new one. Kim On Tue, Aug 24, 2010 at 9:09 PM, tatebn brandonnt...@gmail.com wrote: I'm using transactions

Re: [android-developers] Database transaction help needed.

2010-08-24 Thread Kostya Vasilyev
Transactions are per-connection. That's on purpose, so a connection sees all changes made by others only once are of them are complete. Either switch to one connection, or don't use transactions, preferably both. -- Kostya Vasilyev -- http://kmansoft.wordpress.com 24.08.2010 23:21 пользователь