[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 220
  • Last Modified:

The "@@Cursor_Rows" is getting me "-1"????

When I use the @@CURSOR_ROWS global variable in SQL Server, it is getting me -1 as an answer, although I know that the cursor returns more than 1 row.
I tried to change the setup configuration in sp_configure, but it did not work.

Is there a setup variable that I must know about so that it works properly?

Thanks
0
arida
Asked:
arida
1 Solution
 
xenon_jeCommented:
Can you post your cursor? If the last opened cursor is a dynamic one, than its normal that the @@CURSOR_ROWS is -1.

So please post the cursor you try to open.
thx... xenon
0
 
ispalenyCommented:
Open your cursor as static. Now it can accumulate changes from other users, so it cannot return an accurate rowcount.
0
 
CleanupPingCommented:
arida:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
 
monosodiumgCommented:
No comment has been added to this question in more than 268 days, so it is now classified as abandoned.

I will leave the following recommendation for this question in the Cleanup topic area:
   Accept: xenon_je http:#8193611

Any objections should be posted here in the next 4 days. After that time, the question will be closed.

monosodiumg
EE Cleanup Volunteer
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now