Lesson 5: Upgrading a Data-tier Application

In this lesson, you will use the updated data-tier application (DAC) package you created in the previous lesson to upgrade the DAC you deployed to your test instance of the Database Engine in Lesson 2.

Procedures

Deploying the DAC

  1. In the SQL Server Management Studio Object Explorer pane, navigate to the node for the test instance where you want to deploy the DAC, and then open the Management node under that instance. Open the Data-tier Applications node, right-click on SampleDAC and select Upgrade Data-tier Application….

  2. Review the information on the Introduction page, and then select Next.

  3. On the Select Package page, select the Browse button to specify the DAC package file. The file open dialog opens to the default location for DAC package files. If Navigate to the folder to which you saved the SampleDAC.dacpac file from the previous lesson.

  4. Select the SampleDAC.dacpac file and select Open. After selecting the DAC package file, the DAC details section has a read-only display of the information from the package.

  5. Click Next to proceed.

  6. The Select Package page displays a progress bar as it validates the objects defined in the DAC package. When the validation completes you are taken to the Review Policy page.

  7. The Review Policy page reports the results of evaluating the IsCaseSensitive policy against the instance you selected. If the evaluation failed, you can select the Ignore policy violations check box to proceed with this deployment. ClickNext to proceed to the Detect Change page.

  8. the wizard checks for changes made to the database after the original DAC was deployed. The Detect Change page should report that the database has not changed. Click Next to proceed to the Summary page.

  9. On the Summary page, review the settings that will be used to upgrade the DAC, and then click Next.

  10. The wizard updates the DAC metadata in the msdb database, and then updates all of the database objects to the state defined in the new DAC. Review the Upgrade DAC page to ensure all of the deployment actions were successful. Select Finish to end the wizard.

  11. Right-click on the node for the test instance and select Refresh. Open the SampleDAC node under the Databases node, and open the Tables node to see that the SalesAssociate table has been added to the database.

Next Steps

You have successfully deployed a DAC. Next, you will learn how to delete the DAC using Management Studio. See Lesson 6: Deleting a Data-tier Application.