ExecuteNonQuery() public méthode

public ExecuteNonQuery ( StorageTypes storageType, string dbConnString, string query ) : void
storageType StorageTypes
dbConnString string
query string
Résultat void
 public void DBExecuteNonQuery(string dbType, string dbConnStr, string query)
 {
     try
     {
         //if (!IsAppAuthorised(m_dialPlanContext.SIPDialPlan.AuthorisedApps, "dbexecutenonquery"))
         //{
         //    Log("You are not authorised to use the DBExecuteNonQuery application, please contact [email protected].");
         //}
         if (ServiceLevel == CustomerServiceLevels.Free)
         {
             Log("Your service level of " + ServiceLevel + " is not authorised to use the " + System.Reflection.MethodBase.GetCurrentMethod().Name + " method.");
         }
         else
         {
             StorageTypes storageType = GetStorageType(dbType);
             if (storageType != StorageTypes.Unknown)
             {
                 StorageLayer storageLayer = new StorageLayer(storageType, dbConnStr);
                 storageLayer.ExecuteNonQuery(storageType, dbConnStr, query);
                 Log("DBExecuteNonQuery successful for " + query + ".");
             }
             else
             {
                 Log("Exception DBExecuteNonQuery did not recognise database type " + dbType + ".");
             }
         }
     }
     catch (Exception excp)
     {
         Log("Exception DBExecuteNonQuery. " + excp.Message);
     }
 }
 public void DBExecuteNonQuery(string dbType, string dbConnStr, string query)
 {
     try
     {
         if (!IsAppAuthorised(m_dialPlanContext.SIPDialPlan.AuthorisedApps, "dbexecutenonquery"))
         {
             Log("You are not authorised to use the DBExecuteNonQuery application, please contact [email protected].");
         }
         else
         {
             StorageTypes storageType = GetStorageType(dbType);
             if (storageType != StorageTypes.Unknown)
             {
                 StorageLayer storageLayer = new StorageLayer(storageType, dbConnStr);
                 storageLayer.ExecuteNonQuery(storageType, dbConnStr, query);
                 Log("DBExecuteNonQuery successful for " + query + ".");
             }
             else
             {
                 Log("Exception DBExecuteNonQuery did not recognise database type " + dbType + ".");
             }
         }
     }
     catch (Exception excp)
     {
         Log("Exception DBExecuteNonQuery. " + excp.Message);
     }
 }