Unable to reconnect to database: failed to load string for error 658 when deploying to SQL Server 2012 SP1

Proposed Answer Unable to reconnect to database: failed to load string for error 658 when deploying to SQL Server 2012 SP1

  • Monday, November 26, 2012 6:34 PM
     
     

    Hi,

    when I try to deploy to our new SQLServer 2012SP1 server I get this error:

    "Unable to reconnect to database: failed to load string for error 658 [...]"

    According to some internet research error 658 has to do with increased partitions :

    "Could not enable support for increased partitions in database '%.*ls' because %S_MSG."

    On MSDN it says that this is enabled by default in SS2012 and the stored proc to enable it should no longer be used. Seems like a bug?

All Replies

  • Monday, November 26, 2012 10:55 PM
    Owner
     
     

    Can you connect to the database manually in SQL Server Object Explorer or via SSMS?

    Thanks,

    Janet Yeilding

  • Monday, November 26, 2012 10:57 PM
     
     

    Yes. The connection test is also successful in Visual Studio. I'm using VS2012 with the November SSDT and all the other updates.

    Also the error appears almost immediately, so no timeout.

    • Edited by roederja Monday, November 26, 2012 10:58 PM
    •  
  • Monday, November 26, 2012 11:39 PM
    Owner
     
     

    Does publishing an empty database project to the server result in the same error?  If not, can you pass a minimal repro from your project to recreate the issue?  Also please confirm whether or not it occurs when the advanced publish setting "Ignore partition schemes" is enabled.

    Thanks,

    Janet Yeilding

  • Monday, November 26, 2012 11:45 PM
     
     
    Ignore partition schemas has no effect. Will try the empty database tomorrow.
  • Tuesday, November 27, 2012 10:43 AM
     
     
    Ok turns out this is fairly easy to reproduce. It happens when your solution target is set to SQL server 2008 and you try to deploy to SQL server 2012. I can't change my solution target because our production servers are still on SQL server 2008. Can this be fixed?
  • Tuesday, November 27, 2012 7:38 PM
    Owner
     
     Proposed Answer
    Thanks for clarifying the repro.  SSDT doesn't make guarantees about the deployment to a target server that is different than the platform specified in the project.  If the platform is incompatible, it may or may not work.  You can uncheck Allow incompatible platform in the Advanced publish settings if you wish to block in this case.
  • Tuesday, November 27, 2012 11:22 PM
     
     
    Ok, I would certainly appreciate a better error message than "error 658" though ;)
  • Wednesday, January 02, 2013 11:44 AM
     
     
    I tried again after setting the target to SQL server 2012. And it still doesn't work if you reference any dacpac file. The referenced dacpac file also has the target set to SQL server 2012. I can send you a sample dacpac file if you want, but a dacpac file created from an empty db project should already do the trick.
    • Edited by roederja Wednesday, January 02, 2013 12:43 PM
    •  
  • Monday, January 07, 2013 5:19 PM
    Owner
     
     
    Are you getting the same error or a different one?  Also, please elaborate on the structure of the project(s)-- what kind of reference is it (Same database, different database, etc)?
  • Wednesday, January 09, 2013 7:29 PM
     
     
    Same error. The reference is same server, different database.