Greetings, i'm using DataTable to transfer through WCF channel.
I know, thats a bad solution, however it's a necessary by system design.
So, i've encountered a problem...
In this code, as you can see, i'm populating datatable with dataadapter.
using (var session = DatabaseManager.SessionFactory.OpenSession())
{
using (var conn = session.Connection as MySqlConnection)
{
var adapter = new MySqlDataAdapter(string.Format("SELECT * FROM {0}", dt.TableName), conn);
adapter.MissingSchemaAction = MissingSchemaAction.AddWithKey;
adapter.Fill(dt);
dt.AcceptChanges();
}
}
When i checking DataTable constraints property, it's filled.
BUT! When datatable comes to client side, constraints vanished. AcceptChanges not working here for me...