Added Command Timeout to each query that did not have a specified timeout
This commit is contained in:
@@ -1248,6 +1248,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "addContent";
|
||||
// Input All Fields - Except Calculated Columns
|
||||
cm.Parameters.AddWithValue("@Number", _Number);
|
||||
@@ -1299,6 +1300,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "addContent";
|
||||
// Input All Fields - Except Calculated Columns
|
||||
cm.Parameters.AddWithValue("@Number", number);
|
||||
@@ -1365,6 +1367,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
//Volian.Base.Library.vlnStackTrace.ShowStackLocal("ContentID={0}", _ContentID.ToString());
|
||||
cm.CommandText = "updateContent";
|
||||
// All Fields including Calculated Fields
|
||||
@@ -1437,6 +1440,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "updateContent";
|
||||
// Input All Fields - Except Calculated Columns
|
||||
cm.Parameters.AddWithValue("@ContentID", contentID);
|
||||
@@ -1480,6 +1484,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "deleteContent";
|
||||
cm.Parameters.AddWithValue("@ContentID", criteria.ContentID);
|
||||
cm.ExecuteNonQuery();
|
||||
@@ -1502,6 +1507,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "deleteContent";
|
||||
// Input PK Fields
|
||||
cm.Parameters.AddWithValue("@ContentID", contentID);
|
||||
@@ -1554,6 +1560,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "existsContent";
|
||||
cm.Parameters.AddWithValue("@ContentID", _ContentID);
|
||||
int count = (int)cm.ExecuteScalar();
|
||||
|
Reference in New Issue
Block a user