global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
if ((this.IsBinarySerialized(info, context) == true)) {
this.InitVars(false);
global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler1 = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
this._adapter.DeleteCommand.CommandText = @"DELETE FROM [c_stick_distribute] WHERE (([e_distribute_no] = @Original_e_distribute_no) AND ((@IsNull_e_pol_no_begin = 1 AND [e_pol_no_begin] IS NULL) OR ([e_pol_no_begin] = @Original_e_pol_no_begin)) AND ((@IsNull_e_pol_no_end = 1 AND [e_pol_no_end] IS NULL) OR ([e_pol_no_end] = @Original_e_pol_no_end)) AND ((@IsNull_i_ag = 1 AND [i_ag] IS NULL) OR ([i_ag] = @Original_i_ag)) AND ((@IsNull_i_ag_sub = 1 AND [i_ag_sub] IS NULL) OR ([i_ag_sub] = @Original_i_ag_sub)) AND ((@IsNull_i_distribute = 1 AND [i_distribute] IS NULL) OR ([i_distribute] = @Original_i_distribute)) AND ((@IsNull_d_distribute = 1 AND [d_distribute] IS NULL) OR ([d_distribute] = @Original_d_distribute)) AND ((@IsNull_n_pol_dist = 1 AND [n_pol_dist] IS NULL) OR ([n_pol_dist] = @Original_n_pol_dist)) AND ((@IsNull_s_type = 1 AND [s_type] IS NULL) OR ([s_type] = @Original_s_type)))";
this._adapter.UpdateCommand.CommandText = @"UPDATE [c_stick_distribute] SET [e_distribute_no] = @e_distribute_no, [e_pol_no_begin] = @e_pol_no_begin, [e_pol_no_end] = @e_pol_no_end, [i_ag] = @i_ag, [i_ag_sub] = @i_ag_sub, [i_distribute] = @i_distribute, [d_distribute] = @d_distribute, [n_pol_dist] = @n_pol_dist, [s_type] = @s_type WHERE (([e_distribute_no] = @Original_e_distribute_no) AND ((@IsNull_e_pol_no_begin = 1 AND [e_pol_no_begin] IS NULL) OR ([e_pol_no_begin] = @Original_e_pol_no_begin)) AND ((@IsNull_e_pol_no_end = 1 AND [e_pol_no_end] IS NULL) OR ([e_pol_no_end] = @Original_e_pol_no_end)) AND ((@IsNull_i_ag = 1 AND [i_ag] IS NULL) OR ([i_ag] = @Original_i_ag)) AND ((@IsNull_i_ag_sub = 1 AND [i_ag_sub] IS NULL) OR ([i_ag_sub] = @Original_i_ag_sub)) AND ((@IsNull_i_distribute = 1 AND [i_distribute] IS NULL) OR ([i_distribute] = @Original_i_distribute)) AND ((@IsNull_d_distribute = 1 AND [d_distribute] IS NULL) OR ([d_distribute] = @Original_d_distribute)) AND ((@IsNull_n_pol_dist = 1 AND [n_pol_dist] IS NULL) OR ([n_pol_dist] = @Original_n_pol_dist)) AND ((@IsNull_s_type = 1 AND [s_type] IS NULL) OR ([s_type] = @Original_s_type)));
SELECT e_distribute_no, e_pol_no_begin, e_pol_no_end, i_ag, i_ag_sub, i_distribute, d_distribute, n_pol_dist, s_type FROM c_stick_distribute WHERE (e_distribute_no = @e_distribute_no)";
global::System.Collections.Generic.List<global::System.Data.DataRow> realUpdatedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
for (int i = 0; (i < updatedRows.Length); i = (i + 1)) {
throw new global::System.ApplicationException("The transaction cannot begin. The current data connection does not support transa" +
"ctions or the current state is not allowing the transaction to begin.");
}
global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter> adaptersWithAcceptChangesDuringUpdate = new global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter>();
global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection> revertConnections = new global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection>();
int result = 0;
global::System.Data.DataSet backupDataSet = null;
if (this.BackupDataSetBeforeUpdate) {
backupDataSet = new global::System.Data.DataSet();
backupDataSet.Merge(dataSet);
}
try {
// ---- Prepare for update -----------
//
if ((this._c_stick_distributeTableAdapter != null)) {