Showing posts with label exist. Show all posts
Showing posts with label exist. Show all posts

Monday, March 26, 2012

Fetch within a fetch

Is it possible to have fetch within a fetch? I am getting this error message "A cursor with the name 'crImgGrp' does not exist." So i separate the process into two stored procedures?

CREATE PROCEDURE TrigSendPreNewIMAlertP2
@.REID int

AS

Declare @.RRID int
Declare @.ITID int

Declare @.intIMEmail varchar(300)

Declare crReqRec cursor for
select RRID from RequestRecords where REID = @.REID and RRSTatus = 'IA' and APID is not null
open crReqRec
fetch next from crReqRec
into
@.RRID

Declare crImpGrp cursor for
select ITID from RequestRecords where RRID = @.RRID
open crImpGrp
fetch next from crImgGrp
into
@.ITID
while @.@.fetch_status = 0

EXEC TrigSendNewIMAlertP2 @.ITID

FETCH NEXT FROM crImpGrp
into
@.ITID

close crImpGrp
deallocate crImpGrp

while @.@.fetch_status = 0

FETCH NEXT FROM crReqRec
into
@.RRID

close crReqRec
deallocate crReqRec
GO... I'd re-think a different solution than what you want to do.

Monday, March 19, 2012

Fatal Error 7105 ... text, ntext, or image node does not exist

I'm getting the following in error in Enterprise Manager:
Fatal Error 7105 ... text, ntext, or image node does not exist
It seems that a row in a table has become corrupt or something because when
I try to query for that row or scroll down in the table to view the row (the
preceding rows display fine), that is when I get this error. Can a row that
causes this error be salvaged or deleted or something? It seems it is this
one row that is causing the problem. Is that right?
I found this KB article that suggests applying a hotfix.
http://support.microsoft.com/kb/890755
The hotfix seems to have come out between SP 3a & SP 4. I already have
Service Pack 4 installed, so I'm wondering if this proposed hotfix is already
part of SP 4 or if I should try to apply the hotfix?
I don't want to mess up my box, but I need this error resolved.
If anyone can offer furter advice, I would appreciated (and then I can get a
broken app back up and running).
Thanks
I have a correction to my post.
I'm getting the following error in Enterprise Manager:
[Microsoft][ODBC SQL Server Driver][SQL Server]Page (1:6890), slot 35 for
text, ntext, or image node does not exist.
In my web app, the error is:
Fatal Error 7105 ... text, ntext, or image node does not exist

Fatal Error 7105 ... text, ntext, or image node does not exist

I'm getting the following in error in Enterprise Manager:
Fatal Error 7105 ... text, ntext, or image node does not exist
It seems that a row in a table has become corrupt or something because when
I try to query for that row or scroll down in the table to view the row (the
preceding rows display fine), that is when I get this error. Can a row that
causes this error be salvaged or deleted or something? It seems it is this
one row that is causing the problem. Is that right?
I found this KB article that suggests applying a hotfix.
http://support.microsoft.com/kb/890755
The hotfix seems to have come out between SP 3a & SP 4. I already have
Service Pack 4 installed, so I'm wondering if this proposed hotfix is alread
y
part of SP 4 or if I should try to apply the hotfix?
I don't want to mess up my box, but I need this error resolved.
If anyone can offer furter advice, I would appreciated (and then I can get a
broken app back up and running).
ThanksI have a correction to my post.
I'm getting the following error in Enterprise Manager:
[Microsoft][ODBC SQL Server Driver][SQL Server]Page (1:6890), sl
ot 35 for
text, ntext, or image node does not exist.
In my web app, the error is:
Fatal Error 7105 ... text, ntext, or image node does not exist

Fatal Error 7105 ... text, ntext, or image node does not exist

I'm getting the following in error in Enterprise Manager:
Fatal Error 7105 ... text, ntext, or image node does not exist
It seems that a row in a table has become corrupt or something because when
I try to query for that row or scroll down in the table to view the row (the
preceding rows display fine), that is when I get this error. Can a row that
causes this error be salvaged or deleted or something? It seems it is this
one row that is causing the problem. Is that right?
I found this KB article that suggests applying a hotfix.
http://support.microsoft.com/kb/890755
The hotfix seems to have come out between SP 3a & SP 4. I already have
Service Pack 4 installed, so I'm wondering if this proposed hotfix is already
part of SP 4 or if I should try to apply the hotfix?
I don't want to mess up my box, but I need this error resolved.
If anyone can offer furter advice, I would appreciated (and then I can get a
broken app back up and running).
ThanksI have a correction to my post.
I'm getting the following error in Enterprise Manager:
[Microsoft][ODBC SQL Server Driver][SQL Server]Page (1:6890), slot 35 for
text, ntext, or image node does not exist.
In my web app, the error is:
Fatal Error 7105 ... text, ntext, or image node does not exist