1

I am using DAAB. Plz guide me do we need to check and clsoe connections manually after a db call ?

thanks

user576510
  • 5,777
  • 20
  • 81
  • 144

1 Answers1

0

Enterprise library takes care of opening and closing connections for you.

You don't need to write code to do this.

A way of using Entlib 5.0 DAAB (without unity or any other dependency injection) is :

public DataSet someMethod()
{
    database = new SqlDatabase(connectionString);
    return database.ExecuteDataSet("procName", valparam1, valparam2);
} 
Nicolas De Irisarri
  • 1,077
  • 1
  • 14
  • 27