S
Suresh700
Guest
Hi,
I have a data table and I was able to add unique constraint to a data column using
dataTable.Constraints.Add(new UniqueConstraint(new DataColumn[] { dataTable.Columns["Name"] }));
The issue I am trying to solve is, when user decides to insert a bunch of rows first and then enter the data, with this constraint in place, data table throws an unique constraint error. Is there any way to make unique constraint ignore when its blank?
Continue reading...
I have a data table and I was able to add unique constraint to a data column using
dataTable.Constraints.Add(new UniqueConstraint(new DataColumn[] { dataTable.Columns["Name"] }));
The issue I am trying to solve is, when user decides to insert a bunch of rows first and then enter the data, with this constraint in place, data table throws an unique constraint error. Is there any way to make unique constraint ignore when its blank?
Continue reading...