“找不到存储过程" [英] "could not find stored procedure"

查看:64
本文介绍了“找不到存储过程"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在维护一个具有 SQL Server 2005 后端的经典 ASP 网站.对于一小部分新功能,我编写了一个存储过程来执行插入操作.这是数据库中唯一的用户存储过程.

当我尝试从代码中调用存储过程时,出现以下错误:

<前>Microsoft OLE DB Provider for SQL Server 错误80040e14"找不到存储过程InsertGroup"./newGroup.asp,第 84 行

数据库使用 SQL Server 身份验证.当我使用与连接字符串相同的用户/密码连接到 Visual Studio 中的数据库服务器时,存储过程不可见,但所有表都可见.

用户具有数据读取者和数据写入者角色以及对存储过程的显式执行权限.

我错过了什么?

更新:抱歉,服务器管理员错误地告知我它是 2000 服务器,而实际上它是 2005 服务器(在 Windows Server 2003 x64 上运行).

解决方案

耻辱之路:

连接字符串指向实时数据库.错误消息完全准确 - 存储过程仅存在于开发数据库中.感谢所有提供出色答案的人,对于浪费您的时间,我深表歉意.

I am maintaining a classic ASP website that has a SQL Server 2005 backend. For a small piece of new functionality I wrote a stored procedure to do an insert. This is the only user stored procedure in the database.

When I attempt to call the stored procedure from code I get the following error:

Microsoft OLE DB Provider for SQL Server error '80040e14' 
Could not find stored procedure 'InsertGroup'. 
/newGroup.asp, line 84 

The DB uses SQL Server authentication. When I connect to the DB server in Visual Studio using the same user/pw as in the connection string the stored procedure is not visible but all tables are.

The user has datareader and datawriter roles and explicit execute permission on the stored procedure.

What am I missing?

UPDATE: My apologies, the server admin misinformed me that it was a 2000 server when it is actually a 2005 server (running on Windows Server 2003 x64).

解决方案

Walk of shame:

The connection string was pointing at the live database. The error message was completely accurate - the stored procedure was only present in the dev DB. Thanks to all who provided excellent answers, and my apologies for wasting your time.

这篇关于“找不到存储过程"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆