Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
RecCount() And Filters
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00531079
Message ID:
00531096
Views:
13
>>I've been wondering this for a while: Is there an accurate way to determine how many records are in a filtered table? RecCount() doesnt' work, it's not affected by filters. _TALLY doesn't work, Filters aren't an SQL command. (or at least Set Filter To isn't).
>>
>>What am I missing? Surely you don't have to select it to a cursor to find out how many were returned?
>>
>>TIA!
>
>* Set your filter somewhere
>set filter to docnumber = 'ADL'
>locate
>
>* What is filter to get count
>lcfilter = SET('filter')
>count for &lcfilter to lnHowManyFilteredRecordsAreThere

You don't need to use condition here. COUNT respects it by itself.
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform