I'm not violating FOREIGN KEY RELATIONSHIPS, since I can perform this update directly in the relational database. The problem seems to be with using .NET 2003. I've run tests, and I can perform the same update within the database, just not via .NET
dorianr
Posts
-
datagrid update failure -
datagrid update failureHi Sascha, I'm wondering if there is a problem with the datagrid in .NET 2003 (I have experienced other bugs, but that is anther story). The two tables that I'm discussing are both lookup table that are in the Administration module (not all users have access). I can solve this problem by adding a numeric, primary key to the PERMISSIONS_TYPE lookup table. I have no idea why using a PK for PERMISSION_TYPE would not let an Administrator update the permission type DESCRIPTION. This solution isn't very feasible, since I'm on the last part of a large project - it would set us back by a lot. Thanks, Randy
-
datagrid update failureI have a C# windows appliation with an Access database. There are 2 tables: USERS and PERMISSION_TYPES. Table definitions are: Table Name: USERS Fields: First_Name Last_Name Address PERMISSION_TYPE (FK to PERMISSION_TYPES) Table Name: PERMISSION_TYPES Fields: PERMISSTION_TYPE (PK) DESCRIPTION The tables are linked vis the PERMISSION_TYPE field. I can make successful updates to the database, however, I'm trying to use a datagrid for each table so the user can Insert, Update, and Delete records in each table. When the PERMISSION_TYPES.DESCRIPTION field is changed, an error message is returned that states: "The record cannot be deleted or changed because table 'USERS' includes releated records" This doesn't make any sense to me, since the DESCRIPTION field is not a Primary Key, and the updates are successful within Access. I have used the generated Update code, and I have written my own update code - I get the same error message. Does anyone know what is wrong?:( Thanks so much, Randy dorianr@mail.com