Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
_Tally and other 'global' variables
Message
From
23/09/1998 08:37:22
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00139598
Message ID:
00139760
Views:
33
>What is the general concensus about using the global variables such as _tally.
>
>select * from sometable into cursor somecursor
>...
>if _tally>0
>
>verses
>
>select * from sometable into cursor somecursor
>...
>if reccount("somecursor")>0
>
>
>and other constructions. I can see using _screen as it is the only way to manipulate the fox window, but what of the others? Seems to me that if there is an 'encapsulated' way of doing things, than it should be done that way.
>
>Just curious about other opinions.
>Thanks
Hi,
Except _tally OK but I hate to have different idea about _tally than other folks. _tally, to my arguable experience doesn't work correctly always and depends on some settings. ie: if collating sequence is not machine, executing an SQL returning many rows (reccount() returns correct number) you could get _tally = 0. To test it simply set collate to "TURKISH" (it hit me with that sequence), index some field and add some records, execute your SQL. _tally returns 0 whatever the actual match count is. Set collate to machine and _tally starts to return correct values.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform