Base solution for your next web application
Open Closed

AlterTableOperation error when update-database for mysql db #2400


User avatar
0
najeebalmajeedy created

Hi

I added mysql.data and mysql.data.entity and changed the default connection string to a local mysql database. After that, I added this line before dbcontext

[DbConfigurationType(typeof(MySql.Data.Entity.MySqlEFConfiguration))]

Now, when I try to run update-database from package manager console I got this message in red "AlterTableOperation".

Any idea?


3 Answer(s)
  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    Can you share the full exception message ? You can also read this doc for MySql <a class="postlink" href="http://aspnetboilerplate.com/Pages/Documents/EF-MySql-Integration">http://aspnetboilerplate.com/Pages/Docu ... ntegration</a>.

    Thanks.

  • User Avatar
    0
    najeebalmajeedy created

    <cite>ismcagdas: </cite> Hi,

    Can you share the full exception message ? You can also read this doc for MySql <a class="postlink" href="http://aspnetboilerplate.com/Pages/Documents/EF-MySql-Integration">http://aspnetboilerplate.com/Pages/Docu ... ntegration</a>.

    Thanks.

    Many thanks.. I followed the instructions mentioned in the above link and could finally generate all migrations in mysql db.

  • User Avatar
    0
    ismcagdas created
    Support Team

    I'm glad that it worked for you :)