Up Control query execution

Transactional queries

Last modified on August 15, 2012 17:22

DevForce query requests are atomic. This means that even when a query request resolves into multiple SQL queries, they will all be performed together within the same transaction.

Individual query requests resolve into several SQL queries when the query has includes that fetch related objects or when the query involves one or more sub-queries and query inversion is turned on.

When the root query is performed transactionally, both the main select and the selection of related entities occur within transactional boundaries.

Setting the transaction isolation level on individual commands

Developers can set the transaction isolation level for individual queries and saves.

There is a TransactionSettings class and a TransactionSettings property on the QueryStrategy class.

The TransactionSettings class provides the ability to dynamically set:

  • The Transaction Isolation level of a Query (or Save)
  • The Transaction Timeout to be applied to a Query (or Save)

Note: The Default Transaction Isolation Level when you create the TransactionSettings object is ReadCommitted. This is not always the most performant choice, so be sure to research the isolation level appropriate for your application.

Created by DevForce on October 04, 2010 16:11

This wiki is licensed under a Creative Commons 2.0 license. XWiki Enterprise 3.2 - Documentation. Copyright © 2015 IdeaBlade