Added Command Timeout to each query that did not have a specified timeout
This commit is contained in:
@@ -547,6 +547,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "addZContent";
|
||||
// Input All Fields - Except Calculated Columns
|
||||
cm.Parameters.AddWithValue("@ContentID", ContentID);
|
||||
@@ -580,6 +581,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "addZContent";
|
||||
// Input All Fields - Except Calculated Columns
|
||||
cm.Parameters.AddWithValue("@ContentID", myContent.ContentID);
|
||||
@@ -636,6 +638,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "updateZContent";
|
||||
// All Fields including Calculated Fields
|
||||
cm.Parameters.AddWithValue("@ContentID", ContentID);
|
||||
@@ -683,6 +686,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "updateZContent";
|
||||
// Input All Fields - Except Calculated Columns
|
||||
cm.Parameters.AddWithValue("@ContentID", contentID);
|
||||
@@ -720,6 +724,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "deleteZContent";
|
||||
cm.Parameters.AddWithValue("@ContentID", criteria.ContentID);
|
||||
cm.ExecuteNonQuery();
|
||||
@@ -742,6 +747,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "deleteZContent";
|
||||
// Input PK Fields
|
||||
cm.Parameters.AddWithValue("@ContentID", contentID);
|
||||
@@ -794,6 +800,7 @@ namespace VEPROMS.CSLA.Library
|
||||
using (SqlCommand cm = cn.CreateCommand())
|
||||
{
|
||||
cm.CommandType = CommandType.StoredProcedure;
|
||||
cm.CommandTimeout = Database.SQLTimeout;
|
||||
cm.CommandText = "existsZContent";
|
||||
cm.Parameters.AddWithValue("@ContentID", _ContentID);
|
||||
int count = (int)cm.ExecuteScalar();
|
||||
|
Reference in New Issue
Block a user