I am not overriding any of the SQL command in the data layer, which mean MM.NET is using the commandbuilder. Do you mean I have to tell the data object which field is not allow null if I want to retrieve the primary key? Is this also mean the default value in SQL schema is not compatiable with MM.NET?
Stephen
>The default values are not used by ADO.NET to store the values before performing the update. That is handled by the SQL Server. When you set the flag in MMF to retrieve the primary key, it appends a select statement to the insert. Are you building you own insert statement or are you having MMF use the commandbuilder? If using the commandbuilder, you will want to set the default values of the fields or set AllowNulls to true.
Stephen Lee
--------------------------------
Too much to code
Too little time
--------------------------------