Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Select mostly present entries
Message
From
25/10/2004 03:51:41
Suhas Hegde
Dental Surgeon
Sirsi, India
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 6
OS:
Windows '98
Network:
Windows 98
Database:
Visual FoxPro
Miscellaneous
Thread ID:
00954171
Message ID:
00954182
Views:
21
>>hello,
>>
>>I have say 7 .... 20 result tables from which i have to narrow down a list of probables which exists in most of the tables . i.e. say more 7 tables have a value in 10 tables then that value must be included in the final output.
>>
>>How should i do it ?
>>
>>TIA
>>suhashegde
>
>Hi Suhas,
>
>Create table TestProbables (MyNumber I, TableI I)
>for i=1 to N && where N is the number of tables
>     append from ("table"+transform(m.i))
>     replace TableID with m.i for empty(TableID)
>next
>
>select count(TableID) as Occurrences, MyNumber from TestProbables ;
>           group by MyNumber having  Occurrences >= MAXNUMBER into cursor PossibleCandidates
>
>** There could be a case with the same number in one table, what do we want to do in such case?
Hi Nadya,

U mean same value more than once in the same table..? No there will not be a chance of that. Good code. I couldnt have thought that way.
Will try it out
thanx
suhashegde
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform