March 18, 2008 at 2:56 pm
Hi Everyone,
I utilize @@ROWCOUNT after a RESTORE HEADERONLY FROM DISK... which sets @@ROWCOUNT to how many backup logs are contained in a bak file. I then set another variable to @@ROWCOUNT for the remainder of the script.
ON SQL Server 2000 the @@ROWCOUNT is always set correctly but since we migrated to SQL Server2005 the @@ROWCOUNT is returning zero.
My simple test query is:
RESTORE HEADERONLY FROM DISK = '\path\file.bak'
print @@ROWCOUNT
Please let me know if anyone has seen this behavior and what corrective action I might take.
Thanks in advance.
Regards,
Bret
March 18, 2008 at 3:39 pm
we had the same thing happen to us when we migrated to 2005. We never did find a solution. We used it for log shipping to see how many logs to restore and now we have to use the time of day as an idicator for how many logs are there, which obviously has problems. If you figure it out, please post it here.
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply