Module 4 - Azure SQL
1) Migrate AdventureWorks database from SQL Server instance to Azure SQL using DMA.
2) Update WebApp connection strings to use Azure SQL.
Links:
· How to create Database project;
· https://www.youtube.com/watch?v=K1BJ43GAPQk
https://docs.microsoft.com/en-us/azure/devops-project/azure-devops-project-sql-database
1. 在本地PC安装 SQL Server 2017 Developer 或 Express 版
2. 在本地PC下载和安装 数据迁移助手 Overview of Data Migration Assistant
3. 在本地PC下载和安装 Download SQL Server Management Studio (SSMS)
4. 按照 AdventureWorks Installation and configuration 中的 "Install to SQL Server",通过“恢复备份”的方式在本地 SQL Server 安装数据库 AdventureWorks。
5. 通过在 SSMS 等处执行 “select @@Version” 可以查看 SQL Server 的具体版本。在SQL Server中怎么查看版本号?
6. 怎样解决问题 A network-related or instance-specific error occurred while establishing a connection to SQL Server
Open "SQL Server Configuration Manager" Now Click on "SQL Server Network Configuration" and Click on "Protocols for Name" Right Click on "TCP/IP" (make sure it is Enabled) Click on Properties Now Select "IP Addresses" Tab -and- Go to the last entry "IP All" Enter "TCP Port" 1433. Now Restart "SQL Server .Name." using "services.msc" (winKey + r)
7. SQL Server的起步 Getting Started with SQL Server
8. 参照 Move Local SQL Server Database to SQL Azure or Move SQL Azure Database to Local SQL Server,可以完成任务1)。
9. 通过 Data Migration Assistant,一样可以完成任务1)。
A)

B)

C)

D)

E)

F)

10. 其实我们公司的 Tutor 已经提供 https://github.com/epam-lab/adventure-forks/tree/initial ,需要把解决方案下的项目 AdventureWorks.Web 里的 Web.config 里的 connectionStrings 进行修改。
<connectionStrings>
<add name="AdventureWorks" connectionString="Data Source=chenjo0503.database.windows.net;Initial Catalog=AdventureWorks;Integrated Security=False;User ID=dbadmin;Password=**********;" providerName="System.Data.SqlClient" />
<add name="Entities" connectionString="metadata=res://*/;provider=System.Data.SqlClient;provider connection string="data source=chenjo0503.database.windows.net;initial catalog=AdventureWorks;integrated security=False;User ID=dbadmin;Password=**********;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" />
</connectionStrings>
特别需要注意的是,需要把 integrated security 设置为 False,否则会遇到“SqlException: Windows logins are not supported in this version of SQL Server”。

Module 4 - Azure SQL的更多相关文章
- PowerShell 操作 Azure SQL Active Geo-Replication 实战
<Azure SQL Database Active Geo-Replication简介>一文中,我们比较全面的介绍了 Azure SQL Database Active Geo-Repl ...
- PowerShell 操作 Azure SQL Active Geo-Replication
前文中我们比较全面的介绍了 Azure SQL Database Active Geo-Replication 的主要特点和优势.接下来我们将从自动化的角度介绍如何通过 PowerShell 在项目中 ...
- 使用Automation将Azure SQL DB容灾到本地
前段时间有个客户有如下需求,将Azure SQL Database数据库容灾到本地(备份频率1小时/次). 那么对于这样的需求,我们可以使用Azure Automation来实现自动化备份到本地. 大 ...
- pymssql连接Azure SQL Database
使用pymssql访问Azure SQL Database时遇到"DB-Lib error message 20002, severity 9:\nAdaptive Server conne ...
- 迁移 SQL Server 数据库到 Azure SQL 实战
最近有个维护的项目需要把 SQL Server 2012 的数据库迁移到 Azure SQL 上去,迁移过程可谓一波三折,故在此分享这次迁移中碰到的点点滴滴,希望对朋友们有所帮助. 文章来源:葡萄城产 ...
- Azure SQL Database (19) Stretch Database 概览
<Windows Azure Platform 系列文章目录> Azure SQL Database (19) Stretch Database 概览 Azure SQL Da ...
- Azure SQL Database (20) 使用SQL Server 2016 Upgrade Advisor
<Windows Azure Platform 系列文章目录> Azure SQL Database (19) Stretch Database 概览 Azure SQL Da ...
- Azure SQL Database (21) 将整张表都迁移到Azure Stretch Database里
<Windows Azure Platform 系列文章目录> Azure SQL Database (19) Stretch Database 概览 Azure SQL Da ...
- Azure SQL Database (22) 迁移部分数据到Azure Stretch Database
<Windows Azure Platform 系列文章目录> Azure SQL Database (19) Stretch Database 概览 Azure SQL Da ...
随机推荐
- 【HarmonyOS】【xml】初学XML布局作业
首先要明确,有两种布局方式 线性布局:DirectionalLayout 依赖布局:DependentLayout 好,接下来看一看下面的例子 页面案例1 代码如下: <?xml version ...
- 使用matplotlib中的bar函数绘制柱状图
使用柱状图显示三日电影的票房信息 要显示的数据为2018年12月7日-9日四场电影的票房信息 四场电影分别为:无名之辈,狗十三,毒液:知名守卫者,憨豆特工3 2018年12月7日四场电影票房分别为:[ ...
- 8、Redis五大数据类型---哈希(Hash)
一.哈希(Hash)简介: Redis hash 是一个string类型的field和value的映射表,hash特别适合用于存储对象. Redis hash 是一个键值对集合. 二.常用命令 1.h ...
- 4、Redis基础
redis性能 1.关于测试性能 官方自带的测试性能的工具 redis-benchmark 压力测试工具 #进行压力测试.需求:测试:100个并发连接,100000个请求 #redis-benchma ...
- 为什么在集合中不能使用int关键字作为类型
解释: 1.Int是基本数据类型,Integer是Int的引用类型,定义集合的时候不能使用基本数据类型,需要使用对应的引用类型 2.int是基本数据类型,Integer是他的包装类,包装类主要用在类型 ...
- GIT最基本使用
带'*':必须操作 不带'*':可能需要而且经常用的 常见步骤为下: *1.克隆项目:有两种不同类型的网址(https/ssh) git clone [url] *2.初始化本地仓库 git init ...
- ios消息队列APNS实现和证书申请
iOS消息推送的工作机制可以简单的用下图来概括: Provider是指某个iPhone软件的Push服务器,APNS是Apple Push Notification Service的缩写,是苹果的服务 ...
- 创建Harbor私有仓库
前提 1.安装docker服务 参考:https://blog.csdn.net/weixin_36522099/article/details/108861134 老名字:docker.docker ...
- Vue3 全家桶,从 0 到 1 实战项目,新手有福了
前端发展百花放,一技未熟百技出.未知何处去下手,关注小编胜百书. 我是前端人,专注分享前端内容! 本篇文章主要是,使用 vite 创建一个vue3 项目,实践 vie-router4 vuex4 结合 ...
- mysql数据库总结笔记
一.安装和配置数据库: 下载mysql地址:https://dev.mysql.com/downloads/mysql/ windows下载的版本是installer msi版本:https://de ...