8

We take bacpacs of our Azure V12 database every night and restore locally using the command

C:\Program Files (x86)\Microsoft SQL Server\120\DAC\bin>.\SqlPackage.exe /a:Import /sf:C:\1.bacpac /tdn:db1 /tsn:server1

As of 8 Nov 2016, this command has started failing with :

*** Error importing database:Could not read schema model header information from package. The model version '3.5' is not supported.

This looks similar to a previous problem we had with this process back in April SQL Azure V12 BACPAC import error: β€œThe internal target platform type SqlAzureV12DatabaseSchemaProvider does not support schema file version '3.3'”

That time is was due to a scoped configuration option of maxdop. This time it appears to be another new configuration option which has just appeared (from the model.xml):

<Property Name="TemporalHistoryRetentionEnabled" Value="False" />

Why has this property seemingly randomly appeared in the model.xml ?

Community
  • 1
  • 1
yowl00
  • 181
  • 1
  • 7
  • 1
    As a workaround seems, that running `ALTER DATABASE [dbname] SET TEMPORAL_HISTORY_RETENTION ON` is sufficient to revert the model back as that is the default value for new databases. Dont believe that on its own this command does much except perhaps kick off a background job that periodical cleans up temporal tables. if there aren't any then I assume it's not much of an overhead. – yowl00 Nov 09 '16 at 22:22
  • There is a more recent build here:https://www.microsoft.com/en-us/download/details.aspx?id=54273 but that is still generating the same error with a bacpac downloaded on Jan 1 2017....a nice New Year present! – Peter Grimshaw Jan 01 '17 at 10:34

1 Answers1

6

I ran into the same issue. There is a new data tier applications framework.

It took me a few hours to find it.......

https://www.microsoft.com/en-us/download/details.aspx?id=53876

I installed it and my imports from bacpac files with sqlpackage.exe work again.

Hope that helps!

ps. I am on a 64 bit machine and had to install both the 32 and 64 bit framework upgrade.

Dave
  • 629
  • 6
  • 11