Entity Key mapping bug
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
Entity Key mapping bug
Hi,
I have a problem to use "ADO.Net Entity Data model" and "dotConnect for Oracle" to create Model.edmx.
If any of columns in Oracle 10g tables is not Nullable, that column in Model.edmx will be a Entity Key.
Most of columns in our Oracle Tables do not accept null value, so all those columns in .edmx are Entity Key, we could not update any of those columns from Entity Frameworks project. Here is the error:
The property 'DESCR' is part of the object's key information and cannot be modified
But we could update them in Oracle directly.
Would you tell how to fix these false Entity Key bug?
thanks
I have a problem to use "ADO.Net Entity Data model" and "dotConnect for Oracle" to create Model.edmx.
If any of columns in Oracle 10g tables is not Nullable, that column in Model.edmx will be a Entity Key.
Most of columns in our Oracle Tables do not accept null value, so all those columns in .edmx are Entity Key, we could not update any of those columns from Entity Frameworks project. Here is the error:
The property 'DESCR' is part of the object's key information and cannot be modified
But we could update them in Oracle directly.
Would you tell how to fix these false Entity Key bug?
thanks
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
Entity Key mapping bug
Hi,
Any one could help for this problem?
Thanks
Any one could help for this problem?
Thanks
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
Entity Key mapping bug
Hi,
Please help us for this problem ASAP.
We bought dotConnect for Oracle to build a asp.net web appplication to talk to PeopleSoft/Oracle 10g, we could not change the columns in Oracle table to nullable.
Your timely response will be much appreciated.
thanks
Please help us for this problem ASAP.
We bought dotConnect for Oracle to build a asp.net web appplication to talk to PeopleSoft/Oracle 10g, we could not change the columns in Oracle table to nullable.
Your timely response will be much appreciated.
thanks
It seems you don't have a Primary Key defined in your model, the default Entity Framework behaviour in this case is to generate the Entity Key over all not nullable columns.
You have several ways to deal with the problem:
1. Modify your database objects to contain the explicit Primary Key.
2. Modify the storage part of the generated model with XML Editor. Please note that this way is not very reliable, because running Update model from database wizard will discard the changes.
3. Use Entity Developer to generate Devart Entity model. Our model supports editing the Store part of Entity Framework model. Also, if you have a unique index, in case of Primary Key absence the key will be generated over it.
You have several ways to deal with the problem:
1. Modify your database objects to contain the explicit Primary Key.
2. Modify the storage part of the generated model with XML Editor. Please note that this way is not very reliable, because running Update model from database wizard will discard the changes.
3. Use Entity Developer to generate Devart Entity model. Our model supports editing the Store part of Entity Framework model. Also, if you have a unique index, in case of Primary Key absence the key will be generated over it.
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
Thanks for your reply.
Here is our real case:
1. Modify your database objects to contain the explicit Primary Key.
There are composite keys in most of PeopleSoft/Oracle 10g tables, we could not change it.
2. Modify the storage part of the generated model with XML Editor. Please note that this way is not very reliable, because running Update model from database wizard will discard the changes.
This seems not a good option.
3. Use Entity Developer to generate Devart Entity model. Our model supports editing the Store part of Entity Framework model. Also, if you have a unique index, in case of Primary Key absence the key will be generated over it.
I generated .edmx file from Entity Developer, I could edit the Entity Key property in store part and class part.
But When I add Existing Items to my VS2008 Project, only .edml file added, no edmx file. I am not sure how to use edml file in my asp.net project.
Would you please tell the detail tutorial for how to use .edml file?
Thanks for your prompt help!
Here is our real case:
1. Modify your database objects to contain the explicit Primary Key.
There are composite keys in most of PeopleSoft/Oracle 10g tables, we could not change it.
2. Modify the storage part of the generated model with XML Editor. Please note that this way is not very reliable, because running Update model from database wizard will discard the changes.
This seems not a good option.
3. Use Entity Developer to generate Devart Entity model. Our model supports editing the Store part of Entity Framework model. Also, if you have a unique index, in case of Primary Key absence the key will be generated over it.
I generated .edmx file from Entity Developer, I could edit the Entity Key property in store part and class part.
But When I add Existing Items to my VS2008 Project, only .edml file added, no edmx file. I am not sure how to use edml file in my asp.net project.
Would you please tell the detail tutorial for how to use .edml file?
Thanks for your prompt help!
Last edited by danielliu8 on Tue 30 Jun 2009 22:56, edited 3 times in total.
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
Hi,
I double checked our Oracle tables, we don't have a Primary Key defined in any tables, but we have unique index on some of our comlumns, and most of our columns are not nullable columns.
Is is possible to generate the Entity Key over all the unique indexed columns only? It is not right to generate the entity key on not nullable columns.
Please reply ASAP.
Thanks
I double checked our Oracle tables, we don't have a Primary Key defined in any tables, but we have unique index on some of our comlumns, and most of our columns are not nullable columns.
Is is possible to generate the Entity Key over all the unique indexed columns only? It is not right to generate the entity key on not nullable columns.
Please reply ASAP.
Thanks
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
We have separate class projects to hold the edmx files.
Here is the details what I did:
1.
Add all the existing files which generated from Entity Developer to class project,
2.
Compile class project, failed. I deleted .cs file, keep the designer.cs file, compile success.
3.
Add class project referances to web project, pluralizes all the class names(another bug!).
Compile success finally.
But web project runs failed!
Here is the error:
The specified metadata path is not valid. A valid path must be either an existing directory, an existing file with extension '.csdl', '.ssdl', or '.msl', or a URI that identifies an embedded resource.
I read all your documentations, and post on your forum, but still could not solve this kind of basic function problem.
Quite Frustrated with your poorly documentation and slow response.
Would you please reply within same day???
Thanks for your help.
Here is the details what I did:
1.
Add all the existing files which generated from Entity Developer to class project,
2.
Compile class project, failed. I deleted .cs file, keep the designer.cs file, compile success.
3.
Add class project referances to web project, pluralizes all the class names(another bug!).
Compile success finally.
But web project runs failed!
Here is the error:
The specified metadata path is not valid. A valid path must be either an existing directory, an existing file with extension '.csdl', '.ssdl', or '.msl', or a URI that identifies an embedded resource.
I read all your documentations, and post on your forum, but still could not solve this kind of basic function problem.
Quite Frustrated with your poorly documentation and slow response.
Would you please reply within same day???
Thanks for your help.
This problem was already discussed at our forums.
Please take a look at this post:
http://devart.com/forums/viewtopic.php?t=14973
Please take a look at this post:
http://devart.com/forums/viewtopic.php?t=14973
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
Thanks, Andrey.
It cost too much time to use it now, we will stop using Entity Developer until your new release available.
One important request to your manage team:
None-primary key table and not-nullable columns are basic PeopleSoft database design.
Only if your team could remove the entity key for all the not-nullable columns in your new release, PeopleSoft users would be able to use your products.
Please notify once your new release ready to download.
Thanks a lot.
It cost too much time to use it now, we will stop using Entity Developer until your new release available.
One important request to your manage team:
None-primary key table and not-nullable columns are basic PeopleSoft database design.
Only if your team could remove the entity key for all the not-nullable columns in your new release, PeopleSoft users would be able to use your products.
Please notify once your new release ready to download.
Thanks a lot.
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
I have no problem on generating of Entity Keys over the unique keys in the database, my only problem is generating Entity Keys over not-nullable columns.
To reproduce the problem:
You could create a oracle table without primary key, all the columns not-nullable. It will create entity keys on all the columns automatically.
Please let me know.
thanks
To reproduce the problem:
You could create a oracle table without primary key, all the columns not-nullable. It will create entity keys on all the columns automatically.
Please let me know.
thanks
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
-
- Posts: 33
- Joined: Wed 17 Jun 2009 22:59
- Location: ca
Hi,
Since this bug seems not a quick fix for your company. We need to finish our project by deadline.
Would you tell the details for your Suggestion 2:
" Modify the storage part of the generated model with XML Editor. "?
Would you please show the detail tutorial how to Modify the storage part of the generated model with XML Editor?
Thanks
Since this bug seems not a quick fix for your company. We need to finish our project by deadline.
Would you tell the details for your Suggestion 2:
" Modify the storage part of the generated model with XML Editor. "?
Would you please show the detail tutorial how to Modify the storage part of the generated model with XML Editor?
Thanks