internal int Execute(IEnumerable <SqlParameter> parameters) { try { using (SqlCommand command = new SqlCommand()) { command.Parameters.AddRange(parameters.ToArray()); command.CommandText = querybulder.GetCommandText(); command.CommandType = CommandType; command.Connection = Connection; command.CommandTimeout = CommandTimeout; var count = command.ExecuteNonQuery(); return(count); } } catch (Exception ex) { Console.WriteLine("Execute exception---" + ex.Message + $"{_tableName}"); string text = ($"Table---> {_tableName} Execute exception {ex.Message}{Environment.NewLine}-Inner exception {ex.InnerException} {Environment.NewLine} Command text--{querybulder.GetCommandText()} "); EmailSender sender = new EmailSender(); sender.SendEmailAsync("*****@*****.**", "Error", text); } finally { Connection.Close(); } return(-1); }