transactions

Storage transactions in Redland's Python bindings?

I've currently skimming through the Python-bindings for Redland and haven't found a clean way to do transactions on the storage engine via it. I found some model-transactions within the low-level Redland module: import RDF, Redland storage = RDF.Storage(...) model = RDF.Model(storage) Redland.librdf_model_transaction_start(model._model...

How to minimize transaction overhead in Oracle?

I have to simultaneously load data into a table and run queries on it. Because of data nature, I can trade integrity for performance. How can I minimize the overhead of transactions? Unfortunately, alternatives like MySQL cannot be used (due to non-technical reasons). ...

How programaticaly enable READ COMMITTED SNAPSHOT in SQL Server?

I need to programaticaly enable READ COMMITED SNAPSHOT in SQL Server. How can I do that? ...

mysql insert race condition

How do you stop race conditions in MySQL? the problem at hand is caused by a simple algorithm: select a row from table if it doesn't exist, insert it and then either you get a duplicate row, or if you prevent it via unique/primary keys, an error. Now normally I'd think transactions help here, but because the row doesn't exist, the t...

What is the best way to store and search through object transactions?

We have a decent sized object-oriented application. Whenever an object in the app is changed, the object changes are saved back to the DB. However, this has become less than ideal. Currently, transactions are stored as a transaction and a set of transactionLI's. The transaction table has fields for who, what, when, why, foreignKey, a...

Scope of Oracle transactions when used from ADO.NET and involving triggers?

I am told by someone that when calling Oracle from ADO.net, when calling multiple inserts in a loop, where each insert causes a trigger to fire that includes within it's PL-Sql a Commit statement, that it is impossible to stop that commit from actually commiting the transaction. i.e., I want my ADO.Net code to begin a transaction before...

Why, when I impersonate within a WCF service, can my service not load System.Transactions when I try to run a LINQ to SQL query?

I have a WCF service, hosted in IIS 7.0 that needs to run database queries. In order to get the right permissions to do this I am impersonating within the service as follows: Code [OperationBehavior(Impersonation = ImpersonationOption.Allowed)] public void MyOperation(int arg) Configuration <behavior name="ReceivingServiceBehavior">...

RIA Server Architecture .NET

I'm using WebORB as a remote gateway for Flex projects. I was wondering what would be the best architecture to use on the Server .NET side. At this moment we are using SubSonic to generate a Data Access Layer. Besides that each call from Flex uses a little bit a transaction script pattern because the server side really only acts as a way...

SQL Identity (autonumber) is Incremented Even with a Transaction Rollback

I have a .net transaction with a SQL insert to a MS SQL 2005 DB. The table has an identity primary key. When an error occurs within the transaction, Rollback() is called. The row inserts are rolled back correctly, however the next time I insert data to the table, the identity is incremented as if the rollback never occurred. So essenti...

Transaction level, nolock/readpast and concurrency

We have a system that is concurrently inserted a large amount of data from multiple stations while also exposing a data querying interface. The schema looks something like this (sorry about the poor formatting): [SyncTable] SyncID StationID MeasuringTime [DataTypeTable] TypeID TypeName [DataTable] SyncID TypeID DataC...

Creating 1K IDs, assigning a transactionID to all the rows with concurrency in mind.

Hi, A client is going to request 1K rows of IDs from the server. I have to make sure we have 1K ID's with clientID = -1, if not, I have to insert 1K new ID's into the table. I then have to link those 1K ID's with the clientID return reserved 1K ID's to the client. Is it as simple as wrapping all of this into a Transaction? ...

JDBC: Can I share a connection in a multithreading app, and enjoy nice transactions?

It seems like the classical way to handle transactions with JDBC is to set auto-commit to false. This creates a new transaction, and each call to commit marks the beginning the next transactions. On multithreading app, I understand that it is common practice to open a new connection for each thread. I am writing a RMI based multi-client...

Basic template for Transactions in sqlserver

Hi, If I simply wrap my query with: BEGIN TRANSACTION COMMIT TRANSACTION If anything fails inside of that, will it automatically rollback? From looking at other code, they seem to check for an error, if there is an error then they do a GOTO statement which then calls ROLLBACK TRANSACTION But that seems like allot of work, to hav...

mysql transaction with accounting application

Hello, I have a table like the following: transaction_id user_id other_user_id trans_type amount This table is used to maintain the account transactions for a finance type app. Its double entry accounting so a transfer from User A to B would insert two rows into the table looking like. 1, A, B, Sent, -100 1, B, A, Received, 100 T...

Long Transaction Time Solution for JEE?

A problem I've encountered a few time in my career is in a tiered service architecture a single downstream system can bring down the entire client application if it gets into a state where all its threads are consumed on a deadlock or some sort of infinite loop bug in that system. Under these conditions the server socket on the JEE serve...

Is transactional behaviour ever needed outside of databases?

I wouldn't dare do anything complex in a database without transactions. There is nearly always a simple to use in-built command. But when you start working with other persistent data you just don't get this simple to use transaction support. Some example are file systems web services (none that I've used) Even in non-persistent data ...

How to implement transaction way in vb.net?

Hi, I develop one application using VB.net (200%) that connects to MS-Access Database, I use TableAdapter and Dataset for connection to the Access DB file. I need to implement a simple transaction method (commit, rollback) in saving to the DB? Is there a way to do that without the need to use inline SQL statement? Thanks, ...

Best way to periodically remove a set of records with LINQ to SQL

This is my first crack at a method that is run periodically during the lifetime of my ASP.NET application to clean up expired sessions stored in my database. It seems to work pretty well, but the software engineer in me doesn't feel "right" about this code. I've been working with LINQ to SQL for a few months now, but I'm not very confide...

Transaction for ASP .net Membership

Hi all, I would like to make two database operation in one transaction. Those two operations are Do one insert operation. Create one user (using membership - sql membership provider) I tried TransactionScope but it went to distributed transaction at that line: -- Membership.CreateUser("test", "password", "[email protected]...

Should there be a Transaction for Read Queries?

I've been reading that some devs/dbas recommend using transactions in all database calls, even read-only calls. While I understand inserting/updating within a transaction what is the benefit of reading within a transaction? ...