Create, delete and update problem
Posted: Wed 21 Jul 2010 15:36
Hello,
I generated DataContext models from PostgreSQL database with Entity Developer new version. I can't insert, update and delete all of my tables in my program.
AuthorizationDataContext dc = new AuthorizationDataContext(connectString);
FirstChars f = new FirstChars();
...
dc.FirstChars.InsertOnSubmit(f);
And give me an exception:
System.InvalidOperationException: Can't perform Create, Update or Delete operations on 'Table(FirstChars)' because it is read-only or does not have identity members.
Devart.Data.Linq.Table.l()
Devart.Data.Linq.Table.c(Object A_0, Boolean A_1)
Devart.Data.Linq.Table`1.InsertOnSubmit(TEntity entity)
FirstChars is a simple table with three character varring fields: FirstThreeCharacters, SoftwareName, SoftwareVersion.
The role that i used in ConnectString have got privileges these operations in database.
Best Regards:
Imre
I generated DataContext models from PostgreSQL database with Entity Developer new version. I can't insert, update and delete all of my tables in my program.
AuthorizationDataContext dc = new AuthorizationDataContext(connectString);
FirstChars f = new FirstChars();
...
dc.FirstChars.InsertOnSubmit(f);
And give me an exception:
System.InvalidOperationException: Can't perform Create, Update or Delete operations on 'Table(FirstChars)' because it is read-only or does not have identity members.
Devart.Data.Linq.Table.l()
Devart.Data.Linq.Table.c(Object A_0, Boolean A_1)
Devart.Data.Linq.Table`1.InsertOnSubmit(TEntity entity)
FirstChars is a simple table with three character varring fields: FirstThreeCharacters, SoftwareName, SoftwareVersion.
The role that i used in ConnectString have got privileges these operations in database.
Best Regards:
Imre