{"action":"created","issue":{"url":"https://api.github.com/repos/bleroy/OrchardImportTest/issues/1947","labels_url":"https://api.github.com/repos/bleroy/OrchardImportTest/issues/1947/labels{/name}","comments_url":"https://api.github.com/repos/bleroy/OrchardImportTest/issues/1947/comments","events_url":"https://api.github.com/repos/bleroy/OrchardImportTest/issues/1947/events","html_url":"https://github.com/bleroy/OrchardImportTest/issues/1947","id":66129176,"number":1947,"title":"Migration failed from MS SQL CE to MS SQL Standard","user":{"login":"bleroy","id":1165609,"avatar_url":"https://avatars.githubusercontent.com/u/1165609?v=3","gravatar_id":"","url":"https://api.github.com/users/bleroy","html_url":"https://github.com/bleroy","followers_url":"https://api.github.com/users/bleroy/followers","following_url":"https://api.github.com/users/bleroy/following{/other_user}","gists_url":"https://api.github.com/users/bleroy/gists{/gist_id}","starred_url":"https://api.github.com/users/bleroy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bleroy/subscriptions","organizations_url":"https://api.github.com/users/bleroy/orgs","repos_url":"https://api.github.com/users/bleroy/repos","events_url":"https://api.github.com/users/bleroy/events{/privacy}","received_events_url":"https://api.github.com/users/bleroy/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-04-03T11:27:16Z","updated_at":"2015-04-03T11:27:19Z","closed_at":null,"body":"When i click Migrate button i get this error message:  \n\n##  The migration of the database from SQL Server Compact to SQL Server\nfailed.\n\n##  Migration failed\n\nMigration failed  \n  \nAn error occurred during execution of the database script. The error occurred\nbetween the following lines of the script: \"2244\" and \"2249\". The verbose log\nmight have more information about the error. The command started with the\nfollowing:  \n\"ALTER TABLE [dbo].[Szmyd_Orchard_Modules_Menu_Adva\"  \n\n##  The identifier that starts with 'Szmyd_Orchard_Modules_Menu_AdvancedMenuIt\nemPartRecord_PK__Szmyd_Orchard_Modules_Menu_AdvancedMenuItemPartRecord__000000\n000000030' is too long. Maximum length is 128. [\nhttp://go.microsoft.com/fwlink/?LinkId=178587\n](http://go.microsoft.com/fwlink/?LinkId=178587)\n\n##  OK\n\n* * *\n\nMicrosoft.Web.Deployment.DeploymentDetailedClientServerException: An error\noccurred during execution of the database script. The error occurred between\nthe following lines of the script: \"2244\" and \"2249\". The verbose log might\nhave more information about the error. The command started with the following:  \n\"ALTER TABLE [dbo].[Szmyd_Orchard_Modules_Menu_Adva\"  \nThe identifier that starts with 'Szmyd_Orchard_Modules_Menu_AdvancedMenuItemPa\nrtRecord_PK__Szmyd_Orchard_Modules_Menu_AdvancedMenuItemPartRecord__0000000000\n00030' is too long. Maximum length is 128. [\nhttp://go.microsoft.com/fwlink/?LinkId=178587\n](http://go.microsoft.com/fwlink/?LinkId=178587) \\--->\nSystem.Data.SqlClient.SqlException: The identifier that starts with 'Szmyd_Orc\nhard_Modules_Menu_AdvancedMenuItemPartRecord_PK__Szmyd_Orchard_Modules_Menu_Ad\nvancedMenuItemPartRecord__000000000000030' is too long. Maximum length is 128.  \nat System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean\nbreakConnection)  \nat System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception,\nBoolean breakConnection)  \nat System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning()  \nat System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand\ncmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler,\nTdsParserStateObject stateObj)  \nat System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName,\nBoolean async)  \nat System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult\nresult, String methodName, Boolean sendToPipe)  \nat System.Data.SqlClient.SqlCommand.ExecuteNonQuery()  \nat Microsoft.Web.Deployment.DBStatementInfo.Execute(DbConnection connection,\nDbTransaction transaction, DeploymentBaseContext baseContext, Int32 timeout)  \n\\--- End of inner exception stack trace ---  \nat Microsoft.Web.Deployment.DBStatementInfo.Execute(DbConnection connection,\nDbTransaction transaction, DeploymentBaseContext baseContext, Int32 timeout)  \nat Microsoft.Web.Deployment.DBConnectionWrapper.ExecuteSql(DBStatementInfo\nsqlStatement, DeploymentBaseContext baseContext, Int32 timeout)  \nat Microsoft.Web.Deployment.SqlScriptToDBProvider.AddHelper(DeploymentObject\nsource, Boolean whatIf)  \nat Microsoft.Web.Deployment.SqlScriptToDBProvider.Add(DeploymentObject source,\nBoolean whatIf)  \nat Microsoft.Web.Deployment.DeploymentObject.AddChild(DeploymentObject source,\nInt32 position, DeploymentSyncContext syncContext)  \nat\nMicrosoft.Web.Deployment.DeploymentSyncContext.HandleAddChild(DeploymentObject\ndestParent, DeploymentObject sourceObject, Int32 position)  \nat Microsoft.Web.Deployment.DeploymentSyncContext.SyncChildrenOrder(Deployment\nObject dest, DeploymentObject source)  \nat\nMicrosoft.Web.Deployment.DeploymentSyncContext.SyncChildren(DeploymentObject\ndest, DeploymentObject source)  \nat Microsoft.Web.Deployment.DeploymentSyncContext.SyncChildrenOrder(Deployment\nObject dest, DeploymentObject source)  \nat\nMicrosoft.Web.Deployment.DeploymentSyncContext.SyncChildren(DeploymentObject\ndest, DeploymentObject source)  \nat Microsoft.Web.Deployment.DeploymentSyncContext.ProcessSync(DeploymentObject\ndestinationObject, DeploymentObject sourceObject)  \nat Microsoft.Web.Deployment.DeploymentObject.SyncToInternal(DeploymentObject\ndestObject, DeploymentSyncOptions syncOptions, PayloadTable payloadTable,\nContentRootTable contentRootTable)  \nat Microsoft.Web.Deployment.DeploymentObject.SyncTo(DeploymentProviderOptions\nproviderOptions, DeploymentBaseOptions baseOptions, DeploymentSyncOptions\nsyncOptions)  \nat Microsoft.Web.Deployment.DeploymentObject.SyncTo(String provider, String\npath, DeploymentBaseOptions baseOptions, DeploymentSyncOptions syncOptions)  \nat\nMicrosoft.Web.Deployment.DeploymentObject.SyncTo(DeploymentWellKnownProvider\nprovider, String path, DeploymentBaseOptions baseOptions,\nDeploymentSyncOptions syncOptions)  \nat Microsoft.WebMatrix.DatabaseManager.Client.SqlCeHelper.<>c__DisplayClass6.<\nStartMigrate>b__5(Object sender, DoWorkEventArgs eventArgs)  \nat System.ComponentModel.BackgroundWorker.OnDoWork(DoWorkEventArgs e)  \n\n##  at System.ComponentModel.BackgroundWorker.WorkerThreadStart(Object\nargument)\n\nWork Item Details\n--------------------\n**Original CodePlex Issue:**\t[Issue 18057](http://orchard.codeplex.com/workitem/18057)\n**Status:**\tActive\n**Reason Closed:**\tUnassigned\n**Assigned to:**\tUnassigned\n**Reported on:**\tAug 3, 2011 at 1:25 PM\n**Reported by:**\trm1337\n**Updated on:**\tJan 2, 2013 at 1:27 PM\n**Updated by:**\tIntranetFactory\n**Status:**\tActive\n**Reason Closed:**\tUnassigned\n**Assigned to:**\tUnassigned\n**Reported on:**\tAug 3, 2011 at 1:25 PM\n**Reported by:**\trm1337\n**Updated on:**\tJan 2, 2013 at 1:27 PM\n**Updated by:**\tIntranetFactory\n"},"comment":{"url":"https://api.github.com/repos/bleroy/OrchardImportTest/issues/comments/89259140","html_url":"https://github.com/bleroy/OrchardImportTest/issues/1947#issuecomment-89259140","issue_url":"https://api.github.com/repos/bleroy/OrchardImportTest/issues/1947","id":89259140,"user":{"login":"bleroy","id":1165609,"avatar_url":"https://avatars.githubusercontent.com/u/1165609?v=3","gravatar_id":"","url":"https://api.github.com/users/bleroy","html_url":"https://github.com/bleroy","followers_url":"https://api.github.com/users/bleroy/followers","following_url":"https://api.github.com/users/bleroy/following{/other_user}","gists_url":"https://api.github.com/users/bleroy/gists{/gist_id}","starred_url":"https://api.github.com/users/bleroy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bleroy/subscriptions","organizations_url":"https://api.github.com/users/bleroy/orgs","repos_url":"https://api.github.com/users/bleroy/repos","events_url":"https://api.github.com/users/bleroy/events{/privacy}","received_events_url":"https://api.github.com/users/bleroy/received_events","type":"User","site_admin":false},"created_at":"2015-04-03T11:27:19Z","updated_at":"2015-04-03T11:27:19Z","body":"On *2011-08-05 03:19:22 UTC*, **@BertrandLeRoy** commented:\n\nWorkaround: remove the private key for this table, then migrate, then re-create the key on the target database. The name doesn't matter.\n\r\nWe should change migration code so that it creates shorter PK names.\n"}}