Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Zeroes for no entries
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00437224
Message ID:
00437616
Vues:
19
>I can post the data if you like. Shall I just put it in a message?
>
>I am thinking I can never have the banks show up with zero because there would be nothing there to count. When an entry has no numbers, it is not even in my data. The only way I could get zeroes in this case is to use a AGTABLE of some sort with all the banks. I would then join my results with that table to create the zero entries.

Randall,

If you have a lookups table with all banks and their descriptions, you can do your select first. Then find records, which are not in your select, but in Lookups Banks table and insert from this cursor.
IOW:
1) Your select statement into table TableResult
2) select bankname from Banks where bankname not in (select distinct bankname from TableResult) into cursor curNotInResult
3) select TableResult
append from dbf('curNotInResult')
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform