repetitive query to sysobjects in an ADP

D

dbahooker

I'm connecting to a db with a fairly large number of tables; and it
looks like I have some performance issues.

When I open a view; it's running this crap; I just dont understand if
there's anything that I can do to help this

is this going to be resolved in a service pack anytime soon?

I'm hitting a tiny view and it's going through 100 of these statements;
and I just dont understand what's really going on.

Effectively-- in SQL 2005; the table is now sys.objects and not
sysobjects... is there any way for me to make this faster?

Maybe a synonym?

or could I add a couple of indexes to system tables?

Thanks



select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_CMCONDITIONPROTOCOL_CONDITIONID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_CAPTERM_CAPRATEID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_ORGPOLICYPENALTYGRP_ORGPOLICYID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_EVALCRITERIA_CAREPLANID_PLUS1'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_BENEDENTALAREA_PLANID_PLUS1'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_PLANOUTCOME_OUTCOMEID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_BILLTYPE_FREQUENCYCODE'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_araccountbankinfo_arpaymentchangereason'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_PLANRESTRICTIONGROUP_PLANID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_LOISTATUS_PLANACTIONID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_EDIMEMBERPCP_UID_PLUS1'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_EDI_AUTHDIAG_REFERRALID_PLUS2'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_PHIDIAGTOPICS_DIAGGROUP'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_CAPTERM_COPAYGROUPID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_ORGPOLICYPENALTYGRP_PENALTYGROUPID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_EVALCRITERIA_CRITERIAID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_CODEGROUPERMODIFIER_GROUPID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_CONTRACTINFO_AFFILIATIONID'
select object_name(sotblfk.id), user_name(sotblfk.uid),
object_name(sotblrk.id), user_name(sotblrk.uid) from sysreferences
srfk, sysobjects sofk, sysobjects sotblfk, sysobjects sotblrk where
srfk.constid = sofk.id and srfk.fkeyid = sotblfk.id and srfk.rkeyid =
sotblrk.id and user_name(sofk.uid) = N'dbo' and object_name(sofk.id) =
N'FK_COPAYGROUPDETAIL_COPAYGROUPID'
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top