Well this is fun.
I have content database from a SharePoint 2010 and I´m trying to mount it on my SharePoint 2013 SP1 farm. At around 26% I get a the error
Mount-SPContentDatabase : Operation failed. The index entry of length 902 bytes for the index 'Resources_PK' exceeds the maximum length of 900 bytes. Could not create constraint. See previous errors. Warning! The maximum key length is 900 bytes. The index 'Resources_PK' has maximum length of 1092 bytes. For some combination of large values, the insert/update operation will fail.
At this point in the upgrade sequence SharePoint has deleted all Database Views and atleast the Resources_PK index. If I find a healthy content database and script out the Resources_PK index and apply it to the broken contentdatabase I can finish the query and the index appears. If I try to use the default sql query as defined in the upgrade process I get an error in SQL.
Any ideas? I´ll buy a beer at the next SharePoint conference for anyone that get me on the right track :)