?
Solved

OLEDB recordset count

Posted on 2003-03-25
4
Medium Priority
?
1,142 Views
Last Modified: 2007-12-19
How to get the recordset count in oledb

one way would be to loop thru the recordset and get the count.but is there a way to ge the recordcount
on executing a select query.


what is the equivalent of MoveTo function in oledb
0
Comment
Question by:rlokeshbabu
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 6

Accepted Solution

by:
carchitect earned 500 total points
ID: 8201680
select count(*) from tablename
0
 

Assisted Solution

by:Pathik
Pathik earned 500 total points
ID: 8208559
Solution using ANSI SQL:

Select a.*,b.RECCOUNT
from tble a,(select count(*) RECCOUNT from tble where address = '1 stree') b
where address = '1 street'

RECCOUNT will give total no of recs fetched.


-If you are using ASP/VB then .RecordCount property of the recordset object gives total no of records fetched on execution of the query.
0
 
LVL 17

Expert Comment

by:walterecook
ID: 10352139
No comment has been added lately, so it's time to clean up this TA.
I will leave the following recommendation for this question in the Cleanup topic area:

Split: carchitect {http:#8201680} & Pathik {http:#8208559}

Please leave any comments here within the next four days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

walterecook
EE Cleanup Volunteer
0

Featured Post

Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lotus Notes has been used since a very long time as an e-mail client and is very popular because of it's unmatched security. In this article we are going to learn about  RRV Bucket corruption and understand various methods to Fix "RRV Bucket Corrupt…
Backups and Disaster RecoveryIn this post, we’ll look at strategies for backups and disaster recovery.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question