SSMS 中的调试退出而不进入代码
我最近在我的开发 PC 上安装了 Windows 7,并且有 Visual Studio 2008 Team System Development Edition 和 SQL Server Management Studio 2008,由于某种原因,我似乎无法进入任何 SQL 代码以在 SSMS 中进行调试。
在我进行格式化以支持 Windows 7 之前,我能够在我现在尝试使用相同软件的两个 SQL 服务器上进行调试,因此我猜测这与客户端配置有关。无论如何,我尝试了所有 我可以找到启用 SQL 远程调试的 步骤,但什么也没有工作了。
当我尝试调试或单步进入活动查询窗口时,调试器只是运行代码,而不会在开始处或任何断点处停止。
如果我尝试使用 Visual Studio(以管理员身份运行),我会收到以下错误:
T-SQL 执行结束,没有 调试。你可能没有足够的 调试权限。
有人知道在这里做什么吗?
编辑
我仍然遇到这个问题。我从 MSDN 提供的最新 SQL Server 2008 下载中重新安装了最新的 SQL Server Management Studio,并使用 SP1 对其进行了修补,但仍然出现同样的问题。我办公室的其他人能够使用相同版本的客户端和相同的权限(使用组权限设置)来调试代码,因此我不知道是什么导致了这种情况。
最终编辑
已解决! 该问题只是域身份验证问题。 查看我的答案以获取更大的信息解释。
I've recently put Windows 7 on my development PC, and I have Visual Studio 2008 Team System Development Edition, and SQL Server Management Studio 2008, and for some reason I can't seem to step in to any SQL code for debugging in SSMS.
Before I formatted in favour of Windows 7, I was able to debug on the same two SQL servers I'm trying now with the same software, so I'm guessing it's something to do with client configurations. Regardless, I tried all the steps I could find to enable SQL remote debugging but nothing has worked.
When I attempt to debug or step into the active query window, the debugger simply runs the code without stopping at the start or any breakpoints.
If I try use Visual Studio (running as Administrator) I get the following error:
T-SQL execution ended without
debugging. You may not have sufficient
permissions to debug.
Anyone got a clue what to do here?
EDIT
I'm still having this problem. I re-installed the latest SQL Server Management Studio from MSDN's latest SQL Server 2008 download available, and patched it with SP1, but this same problem still happens. Other people in my office are able to debug code with the same version client, and same permissions (set using group permissions) so I'm at a loss as to what is causing this.
FINAL EDIT
Solved! The issue was simply a domain authentication issue. See my answer for a larger explanation.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您是否确保在服务器资源管理器(在 Visual Studio 中)中,如果右键单击您的连接,则已选中“允许 SQL/CLR 调试”和“应用程序调试”?
Have you made sure that in Server Explorer (In Visual Studio), if you right click on your connection that you have "Allow SQL/CLR Debugging" and "Application Debugging" checked?
今天,我终于解决了这个问题。
我正在编写一个 ASP.NET 应用程序,其中包含以下行:
这引发了以下异常:
我浪费了一点时间应用 KB976494 修补程序,但我很快发现它不起作用。在我的开发人员愤怒期间,我查看了本地“管理员”帐户,发现它按 S-ID 列出了几乎所有成员,因此我认为可能存在域问题。
然后我想到...我记得我是使用个人(非管理员)帐户加入域的,而不是使用域管理员帐户。
这些是解决此问题的最终步骤:
User.IsInRole()
现在可以正常工作,因此出于好奇,我检查了这个问题,它也得到了修复。到目前为止,这是一个很棒的星期五!
Today, I finally solved this.
I was writing an ASP.NET application that included the line:
And this was throwing the following exception:
I wasted a little time applying the KB976494 hotfix, which I soon discovered didn't work. During my developer rage I looked in my local "Administrators" account and noticed it listed almost all members by their S-ID, so figured there may have been a domain problem.
Then it came to me... I remembered I joined the domain with my personal (non-administrator) account, instead of using the domain administrator account.
These were the ultimate steps to fix this issue:
User.IsInRole()
now worked, so out of curiosity I checked this problem, and it was also fixed.This is a great Friday so far!