SQL 向程序发送命令时出现问题

SQL there was a problem sending the command to the program(SQL 向程序发送命令时出现问题)
本文介绍了SQL 向程序发送命令时出现问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的是 Windows 7 和 SQL Server 2008 R2,每当我尝试双击一个 .sql 文件时,我都会收到一些愚蠢的错误将命令发送到程序时出现问题"有谁知道如何解决这个问题?每当我打开 SQL 服务器或 BIDS 时,我都会不断弹出 UAC,但由于某种原因,在 Vis studio 2010 中似乎没问题...哦,我检查了 exe 是否以管理员身份运行,我看到它发布在某处...

I'm using Windows 7 and SQL Server 2008 R2 and whenever I try and double click a .sql file I get some stupid error "there was a problem sending the command to the program" does anyone know how to fix this? I have UAC keep popping up whenever I open SQL server or BIDS, but seems fine with Vis studio 2010 for some reason... oh and I checked that the exe was running as admin, I saw that posted somewhere...

推荐答案

我的一开始也是这样.

运行 regedit 并转到以下键:

Run regedit and go to the following key:

HKEY_CLASSES_ROOT\sqlwb.sql.9.0\Shell\Open\Command

HKEY_CLASSES_ROOT\sqlwb.sql.9.0\Shell\Open\Command

编辑默认值以在末尾添加%1".

Edit the default value to add "%1" to the end.

该值现在应如下所示:

"c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\ssms.exe"/dde "%1"

"c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\ssms.exe" /dde "%1"

(注意 %1 周围的双引号)

(note double quotes around the %1)

这篇关于SQL 向程序发送命令时出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

相关文档推荐

Execute complex raw SQL query in EF6(在EF6中执行复杂的原始SQL查询)
SSIS: Model design issue causing duplications - can two fact tables be connected?(SSIS:模型设计问题导致重复-两个事实表可以连接吗?)
SQL Server Graph Database - shortest path using multiple edge types(SQL Server图形数据库-使用多种边类型的最短路径)
Invalid column name when using EF Core filtered includes(使用EF核心过滤包括时无效的列名)
How should make faster SQL Server filtering procedure with many parameters(如何让多参数的SQL Server过滤程序更快)
How can I generate an entity–relationship (ER) diagram of a database using Microsoft SQL Server Management Studio?(如何使用Microsoft SQL Server Management Studio生成数据库的实体关系(ER)图?)