<bdo id='Yqlpm'></bdo><ul id='Yqlpm'></ul>

        <small id='Yqlpm'></small><noframes id='Yqlpm'>

        <i id='Yqlpm'><tr id='Yqlpm'><dt id='Yqlpm'><q id='Yqlpm'><span id='Yqlpm'><b id='Yqlpm'><form id='Yqlpm'><ins id='Yqlpm'></ins><ul id='Yqlpm'></ul><sub id='Yqlpm'></sub></form><legend id='Yqlpm'></legend><bdo id='Yqlpm'><pre id='Yqlpm'><center id='Yqlpm'></center></pre></bdo></b><th id='Yqlpm'></th></span></q></dt></tr></i><div id='Yqlpm'><tfoot id='Yqlpm'></tfoot><dl id='Yqlpm'><fieldset id='Yqlpm'></fieldset></dl></div>

        <legend id='Yqlpm'><style id='Yqlpm'><dir id='Yqlpm'><q id='Yqlpm'></q></dir></style></legend>

        <tfoot id='Yqlpm'></tfoot>
      1. 如何导入大型 MS SQL .sql 文件?

        时间:2023-11-28
          <bdo id='mhgQK'></bdo><ul id='mhgQK'></ul>

          1. <small id='mhgQK'></small><noframes id='mhgQK'>

                  <tfoot id='mhgQK'></tfoot>
                    <tbody id='mhgQK'></tbody>
                1. <legend id='mhgQK'><style id='mhgQK'><dir id='mhgQK'><q id='mhgQK'></q></dir></style></legend>
                  <i id='mhgQK'><tr id='mhgQK'><dt id='mhgQK'><q id='mhgQK'><span id='mhgQK'><b id='mhgQK'><form id='mhgQK'><ins id='mhgQK'></ins><ul id='mhgQK'></ul><sub id='mhgQK'></sub></form><legend id='mhgQK'></legend><bdo id='mhgQK'><pre id='mhgQK'><center id='mhgQK'></center></pre></bdo></b><th id='mhgQK'></th></span></q></dt></tr></i><div id='mhgQK'><tfoot id='mhgQK'></tfoot><dl id='mhgQK'><fieldset id='mhgQK'></fieldset></dl></div>

                2. 本文介绍了如何导入大型 MS SQL .sql 文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我使用 RedGate SQL 数据比较并生成了一个 .sql 文件,所以我可以在我的本地机器上运行它.但问题是文件超过 300mb,这意味着我无法进行复制和粘贴,因为剪贴板将无法处理它,并且当我尝试在 SQL Server Management Studio 中打开文件时出现错误关于文件太大.

                  I use RedGate SQL data compare and generated a .sql file, so I could run it on my local machine. But the problem is that the file is over 300mb, which means I can't do copy and paste because the clipboard won't be able to handle it, and when I try to open the file in SQL Server Management Studio I get an error about the file being too large.

                  有没有办法运行一个大的 .sql 文件?该文件基本上包含两个新表的数据.

                  Is there a way to run a large .sql file? The file basically contains data for two new tables.

                  推荐答案

                  从命令提示符启动 sqlcmd:

                  sqlcmd -S <server> -i C:<your file here>.sql 
                  

                  只需将 替换为您的 SQL 框的位置,并将 替换为您的脚本名称.不要忘记,如果您使用的是 SQL 实例,则语法是:

                  Just replace <server> with the location of your SQL box and <your file here> with the name of your script. Don't forget, if you're using a SQL instance the syntax is:

                  sqlcmd -S <server>instance.
                  

                  这是您可以传递 sqlcmd 的所有参数的列表:

                  Here is the list of all arguments you can pass sqlcmd:

                  Sqlcmd            [-U login id]          [-P password]
                    [-S server]            [-H hostname]          [-E trusted connection]
                    [-d use database name] [-l login timeout]     [-t query timeout] 
                    [-h headers]           [-s colseparator]      [-w screen width]
                    [-a packetsize]        [-e echo input]        [-I Enable Quoted Identifiers]
                    [-c cmdend]            [-L[c] list servers[clean output]]
                    [-q "cmdline query"]   [-Q "cmdline query" and exit] 
                    [-m errorlevel]        [-V severitylevel]     [-W remove trailing spaces]
                    [-u unicode output]    [-r[0|1] msgs to stderr]
                    [-i inputfile]         [-o outputfile]        [-z new password]
                    [-f  | i:[,o:]] [-Z new password and exit] 
                    [-k[1|2] remove[replace] control characters]
                    [-y variable length type display width]
                    [-Y fixed length type display width]
                    [-p[1] print statistics[colon format]]
                    [-R use client regional setting]
                    [-b On error batch abort]
                    [-v var = "value"...]  [-A dedicated admin connection]
                    [-X[1] disable commands, startup script, environment variables [and exit]]
                    [-x disable variable substitution]
                    [-? show syntax summary] 
                  

                  这篇关于如何导入大型 MS SQL .sql 文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:用于保存整数列表的 SQL 变量 下一篇:使用 SQL Server Server Management Studio 导入/导出数据库

                  相关文章

                    1. <i id='kVcVh'><tr id='kVcVh'><dt id='kVcVh'><q id='kVcVh'><span id='kVcVh'><b id='kVcVh'><form id='kVcVh'><ins id='kVcVh'></ins><ul id='kVcVh'></ul><sub id='kVcVh'></sub></form><legend id='kVcVh'></legend><bdo id='kVcVh'><pre id='kVcVh'><center id='kVcVh'></center></pre></bdo></b><th id='kVcVh'></th></span></q></dt></tr></i><div id='kVcVh'><tfoot id='kVcVh'></tfoot><dl id='kVcVh'><fieldset id='kVcVh'></fieldset></dl></div>
                      <legend id='kVcVh'><style id='kVcVh'><dir id='kVcVh'><q id='kVcVh'></q></dir></style></legend>

                        <bdo id='kVcVh'></bdo><ul id='kVcVh'></ul>

                      <small id='kVcVh'></small><noframes id='kVcVh'>

                    2. <tfoot id='kVcVh'></tfoot>