The value for column 'IsPrimaryKey' in table 'TableDetails' is DBNull
Video Tutorial
1- In below Image i have show that error which occurs during adding ado.net Entity Data Model.
2- Now go to the following Address"Start->All Program->MySQL->MySql Server 5.7 ->MySQL Command Line Client".
3- Run the MySQL Command line Client and Enter your MySql Server Connection Password.
4- Paste Follow Code.
set global optimizer_switch='derived_merge=off';
set optimizer_switch='derived_merge=off';
select @@optimizer_switch;
select @@GLOBAL.optimizer_switch;
5- Hit Enter two time.
6- Now Once again add Ado.net Entity Data Model and you will notice that your model will generate
successfully with the following tables in the database.
If Still same problem occur Please Comment below that i can help you.
In this tutorial we will learn how to fix The value for column 'IsPrimaryKey' in table 'TableDetails' is DBNull error while adding ado.net Entity Data Model.
1- In below Image i have show that error which occurs during adding ado.net Entity Data Model.
2- Now go to the following Address"Start->All Program->MySQL->MySql Server 5.7 ->MySQL Command Line Client".
3- Run the MySQL Command line Client and Enter your MySql Server Connection Password.
4- Paste Follow Code.
set global optimizer_switch='derived_merge=off';
set optimizer_switch='derived_merge=off';
select @@optimizer_switch;
select @@GLOBAL.optimizer_switch;
5- Hit Enter two time.
6- Now Once again add Ado.net Entity Data Model and you will notice that your model will generate
successfully with the following tables in the database.
Remember. After running following code than Restart Visual Studio once again than add ado.net Entity data model to your project.
If Still same problem occur Please Comment below that i can help you.

not working, only what work y change the collation on the field from my table. I dont know why vs dont like "utf8_general ci". Change that and done.
ReplyDeleteThis comment has been removed by the author.
DeleteTo which collation you have changed from utf8_general ci
Deletesry my english is so bad but i hope what you understande me.
ReplyDelete