use MSBuild cmd to build and deploy the database project.
2024-08-30 00:24:44
You can use the below command to implement it.
SET TargetDBName="Database name"
SET DataBaseServer="DB Server name"
SET DbProjectPath="database project folder" C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe /t:Deploy /p:TargetDatabase=%TargetDBName%;TargetConnectionString="Data Source=%DataBaseServer%;User ID=XXX;Password=XXX;Pooling=False" "%DbProjectPath%\DataBaseProjectName.sqlproj"
You may need to add a user on the DB server. Then you can connect the database server with it.
The problem that you may come accross.
Problem 1: error MSB4019: The imported project "C:\Program Files(x86)\MSBuild\Microsoft\VisualStudio\v10.0\SSDT\Microsoft.Data.Tools.Schema.SqlTasks.targets" was not found. Confirm that the path in the <Import> declaration is correc
t, and that the file exists on disk.
Solution1:
Solution2:
Problem2: Could not load file or assembly 'Microsoft.Data.Tools.Components, Version=10.3.0.0' or one of its dependencies
Solution1:
稍后继续。。。
最新文章
- 字典转模型框架 Mantle的使用:国外程序员最常用的iOS模型
- Bash 中的环境变量
- 把word文档中的所有图片导出
- 怎样让SoapHttpClientProtocol不使用系统默认代理
- PD中将Comment 从Name复制值
- Android中设置TextView的颜色setTextColor
- win7下安装redies
- SQL数据库对于保存特殊字符的解决办法
- java collections读书笔记(8)collection框架总览(1)
- PAT (Basic Level) Practise:1013. 数素数
- 双网卡route配置
- CentOS 6.5安装Erlang/OTP 17.0
- USACO 3.2 Magic Squares
- git(创建,提交,回退)
- 用phpcms如何将静态页面制作成企业网站(下)
- js判断文件类型大小并给出提示
- 解决org.hibernate.exception.SQLGrammarException:could not insert
- Java容器解析系列(1) 迭代的进化——从Enumeration到Iterator
- Mysql5.7实现主从复制、基于GTID的主从复制、并行复制
- magento 2.3安装测试数据
热门文章
- 利用Console来调试JS程序、Console用法总结
- Delphi内存操作API函数(备查,并一一学习)
- Windows 技巧
- oracle在一个字符串中查找某个字符出现过几次
- POJ2151-Check the difficulty of problems(概率DP)
- ubuntu之iptables
- 第八章 C#面向对象编程(Object-Oriented Programming,OOP)简介
- XGPush集成(信鸽集成)demo
- C++类包含问题(重复包含和相互包含)
- 一道试题引发的血案 int *ptr2=(int *)((int)a+1);