transactions

Cannot use READPAST in snapshot isolation mode

I have a process which is called from multiple threads which does the following: Start transaction Select unit of work from work table with by finding the next row where IsProcessed=0 with hints (UPDLOCK, HOLDLOCK, READPAST) Process the unit of work (C# and SQL stored procedures) Commit the transaction The idea of this is that a thre...

Is there any free Python to C translator?

Is there any free Python to C translator? for example capable to translate such lib as lib for Fast content-aware image resizing (which already depends on some C libs) to C files? ...

Use analytics tool to tie browser behavior to back end transactions

Can I use an analytics tool like Google Analytics to tie user behavior to back end (Java) transactions? I know I can use the analytics API to store custom data, like an account number or something that I can tie to the log/database created from the Java classes, but is this the best way? What I want to do is see how many users access e...

How can I get SQL Server transactions to use record-level locks?

We have an application that was originally written as a desktop app, lo these many years ago. It starts a transaction whenever you open an edit screen, and commits if you click OK, or rolls back if you click Cancel. This worked okay for a desktop app, but now we're trying to move to ADO.NET and SQL Server, and the long-running transactio...

Cannot save model due to bad transaction? Django

Trying to save a model in Django admin and I keep getting the error: Transaction managed block ended with pending COMMIT/ROLLBACK I tried restarting both the Django (1.2) and PostgreSQL (8.4) processes but nothing changed. I added "autocommit": True to my database settings but that didn't change anything either. Everything that Google...

Implement custom JTA XAResource for using with hibernate

I have two level access to database: the first with Hibernate, the second with JDBC. The JDBC level work with nontransactional tables (I use MyISAM for speed). I want make both levels works within transaction. I read about JTA which can manage distributed transactions. But there is lack information in the internet about how to implement ...

Is Google's App Engine suited for transaction based systems

I am building a web application that is currently PHP with MySQL. There is payment on the website so the db tables are InnoDB with transactions. Can this type of application be implemented in Google's App Engine. ...

How to add Transactions with a DataSet created using the Add Connection Wizard?

I have a DataSet that I have added to my project where I can Insert and Add records using the Add Query function in Visual Studio 2010, however I want to add transactions to this, I have found a few examples but cannot seem to find one that works with these. I know I need to use the SQLClient.SQLTransaction Class somehow. I used the Add...

Does a rollback still occur if I use begin...rescue and an error occurs?

I've got some strange errors happening in my rails app and I'm trying to log better errors instead of the whole stack of passenger stuff that I don't care about. I thought I would do this with a Rescue clause and explicit error handling, like logging the params hash. But I'm concerned if this would interrupt any rollback that is happenin...

MongoDB transactions?

Playing around with MongoDB and NoRM in .NET. Thing that confused me - there are no transactions (can't just tell MongoConnection.Begin/EndTransaction or something like that). I want to use Unit of work pattern and rollback changes in case something fails. Is there still a clean way how to enrich my repository with ITransaction? ...

jdbc nested transactions

What is the behaviour of nested transactions. I am using java + jdbc ? Eg: tx1.begin do stuff1 tx2.begin do stuff2 tx2.commit do stuff1.1 tx1.rollback tx2 is basically inside another function. Will the results from tx2 be persisted ? In case behaviour is db specific, what is it in case of Sql server 2005 ? ...

Transaction management in iBATIS 3 inside an EJB (3.1) container

Is anybody out there using iBATIS 3 as their persistence framework inside an EJB container? I recently started building a new system for which I choose EJB 3.1 (the version of EJB is actually irrelevant to this question) as my app framework and iBATIS 3 (this version is relevant!) as my persistence framework. My business logic is impleme...

Achieving NHibernate Nested Transactions Behavior

Hi all, I'm trying to achieve some kind of nested transaction behavior using NHibernate's transaction control and FlushMode options, but things got a little bit confusing after too much reading, so any confirmation about the facts I list below will be very usefull. What I want is to open one big transaction that splits in little transa...

Transactions in codeigniter with multiple tables.

Hey SO, I'm new to transactions in general, but especially with CodeIgniter. I'm using InnoDB and everything, but my transactions aren't rolling back when I want them to. Here's my code (slightly simplified). $dog_db = $this->load->database('dog', true); $dog_db->trans_begin(); $dog_id = $this->do...

Do Django transactions make my non-db operations atomic?

I have a function that writes file to disk. Using a concurrent server, it is possible (likely even) that this function could be called by two threads, concurrently. Looking at the source code, it seems that wrapping my function up in django.db.transaction will keep both my db operations and my non-db operations atomic. Is this correct...

Shared Data Problem

I am working on an ASP.NET Online Shop. every products has an entity and even a user sells it, its entity should be decreased. because this field is shared between all users, it may be negative (because of the shared data problem). Now, how can I prevent this problem? Can I use transaction for this? If I can, what the isolation level sho...

How do I insert records into 2 SQL tables sharing a dependency when I don't commit until the end?

I keep finding myself in this situtation: I have an ASP.NEt 2.0 app. I have to insert into 2 tables in SQL. There is a dependency between the tables. I insert a record the first using a transaction. Then I move onto the 2nd table. But, because the first isn't committed yet the second one throws a error. ...

NInject2 Interceptor usage with NHibernate transactions

Hello, In my previous project we used NHibernate and Spring.NET. Transactions were handled by adding [Transaction] attribute to service methods. In my current project I'm using NHibernate and NInject 2 and I was wondering if it's possible to solve transaction handling using "Ninject.Extensions.Interception" and similar [Transaction] ...

Does anyone know what these Oracle AQ JMS XA properties do?

I'm using Oracle Advanced Queues via JMS from within Websphere App Server. Does anyone know what effect the following two properties have:- - oracle.jms.useEmulatedXA - oracle.jms.useNativeXA I have seen mentioned in some blogs and quick start guides, usually in sentences along the lines of "Add -Doracle.jms.useEmulatedXA=false -Do...

Does SQLite support transactions across multiple databases?

I've done some searching and also read the FAQ on the SQLite site, no luck finding an answer to my question. It could very well be that my database approach is flawed, but at the moment, I would like to store my data in multiple SQLite3 databases, so that means separate files. I am very worried about data corruption due to my applicati...