Transaction not created. Do i need to configure my database?

C

Chukkalove

In the following edited code sample my transaction instance is being
returned as null after Connection.BeginTransaction();
The database server Im using at the moment is an evaluation version of SQL
Server 2005 while Im waiting for the real one to be delivered.
Im a nooby SQL server user with 2 days experience, so Im not sure if I have
to enable use of Transactions in the server somewhere, I know that in mySQL
(we're migrating) that dependant on the database type, transactions
were/were not available.
Can someone tell me what to do please?
thanks

IDbTransaction transaction;
IDbConnection Connection = GetConnection();
IDbCommand command = Command(sql, Connection);

foobar ....

Connection.Open();
try
{
transaction = Connection.BeginTransaction(); <<<<< No transaction created
here
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top