Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 2k: Developing under seperate schema, deriveparams fails

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2006-10-16 : 07:18:26
Richard writes "Hi
I have just managed to convince our dev team that moving to the MS recommended (sql resourcekit) development environment, with each developer working on their own schema, is a Good Idea.

Trouble is now a bunch of ado connection stuff has stopped working. It appears that it is a bug whereby the DeriveParameters call to sp_procedure_params_rowset does not include a schema name. This has the disadvantage of casually returning ALL Parameters for the stored proc name, which is horribly, horribly wrong.

I have hunted around a bit, found a variety of threads, some ms stuff. We are using MS Enterprise Library and sql server 2k sp4.

Items like:
<http://support.microsoft.com/kb/898086/en-us>
<http://www.mail-archive.com/user-cs@ibatis.apache.org/msg00939.html>


As a workaround I have modded sp_procedure_params_rowset in the following manner:

alter....
as

if @procedure_schema is null
and @procedure_name is not null
begin
select @procedure_schema = user_name()
if not exists
(
select top 1 1
from information_schema.routines
where specific_schema = @procedure_schema
and specific_name = @procedure_name
)
begin
select @procedure_schema = 'dbo'
end
end

.....
.....
.....

Which may or may not be working.

If anyone knows what I am talking about, I would be very very happy to hear back from you!

Rich"
   

- Advertisement -