Setting Package Manager console migration options
Posted: Wed 10 Oct 2012 05:02
My environment is as follows:
Visual Studion 2010
Entity Framework 5
Devart DotConnect: 7.2.96.0
Oracle 11g
I'm attempting to upgrade my database using the Package Manger console command:
PM> Update-Database -Verbose -ConnectionStringName "SID1"
This references the app.config <connectionStrings> section to obtain the connection string. However, migration then throws an exception: "System.InvalidOperationException: Foreign key name 'FK_USERPROFILE_ADDRESS_ADDRESSID' in table USERPROFILE is too long (32 characters). An identifier with more than 30 characters was specified."
I see that I can set some options like "CodeFirstOptions.TruncateLongDefaultNames = True" but how would I do this when using the PM console?
Visual Studion 2010
Entity Framework 5
Devart DotConnect: 7.2.96.0
Oracle 11g
I'm attempting to upgrade my database using the Package Manger console command:
PM> Update-Database -Verbose -ConnectionStringName "SID1"
This references the app.config <connectionStrings> section to obtain the connection string. However, migration then throws an exception: "System.InvalidOperationException: Foreign key name 'FK_USERPROFILE_ADDRESS_ADDRESSID' in table USERPROFILE is too long (32 characters). An identifier with more than 30 characters was specified."
I see that I can set some options like "CodeFirstOptions.TruncateLongDefaultNames = True" but how would I do this when using the PM console?