public void ExecuteUpdateCommand(IDbTransaction p_transaction, object p_object) { TableInformation t_tableInformation = this.GetTableInformations(p_object.GetType()); SqlCommandHelper t_sqlHelper = new SqlCommandHelper(m_providerConfiguration, t_tableInformation); string t_sql = t_sqlHelper.CreateUpdate(p_object); IDbCommand t_cmd = p_transaction.Connection.CreateCommand(); foreach (FieldInformation t_currFieldinformation in t_tableInformation.Fields) { if (t_currFieldinformation.IsPrimaryKey) { continue; } IDbDataParameter t_param = t_cmd.CreateParameter(); t_param.ParameterName = t_sqlHelper.CreateParameterName(t_currFieldinformation.Name); t_param.Value = p_object.GetType().GetProperty(t_currFieldinformation.PropertyName).GetValue(p_object, null); t_cmd.Parameters.Add(t_param); } IDbDataParameter t_paramPK = t_cmd.CreateParameter(); t_paramPK.ParameterName = t_sqlHelper.CreateParameterName(t_tableInformation.PrimaryKey.Name); t_paramPK.Value = p_object.GetType().GetProperty(t_tableInformation.PrimaryKey.PropertyName).GetValue(p_object, null); t_cmd.Parameters.Add(t_paramPK); t_cmd.CommandText = t_sql.ToString(); t_cmd.Transaction = p_transaction; t_cmd.ExecuteNonQuery(); }