Hello:


This patch prevent two things:


1.- Exception throwing when tableMapping parameter is null on methods:

CreateInsertCommand (DataRow row, DataTableMapping tableMapping)
CreateDeleteCommand (DataRow row, DataTableMapping tableMapping)
CreateUpdateCommand (DataRow row, DataTableMapping tableMapping)


2.- Generation of Update commands with ReadOnly columns, i think this patch needs to be extended to Expresion columns too ( i think that field that cannot be included on insert commands cannot be included on update commands )




Two final questions:

1. in CreateDeleteCommand when a row and a tableMapping are passed as parameters the value of a where parameter is :

parameter.Value = row [dsColumnName, DataRowVersion.Current];


and in CreateUpdateCommand is :

parameter.Value = row [dsColumnName];


Well, i think that value for where parameters need to be original value of the column, anything like this:

parameter.Value = row [dsColumnName, DataRowVersion.Original];


2. I think that this line :

e.Status = UpdateStatus.SkipCurrentRow;
on:

private void RowUpdatingHandler (object sender, SqlRowUpdatingEventArgs e)


is not correct, because it makes te line to be not updated, it will be:

e.Status = UpdateStatus.Continue;



��I�m rigth??


Best regards
Carlos Guzm�n �lvarez
Vigo-Spain


_______________________________________________
Mono-list maillist - [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list



_______________________________________________
Mono-list maillist - [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list

Reply via email to