Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
My Grid has no order though one is defined
Message
De
07/06/2007 10:33:14
 
 
À
07/06/2007 10:23:37
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 7 SP1
OS:
Windows XP SP2
Database:
Visual FoxPro
Divers
Thread ID:
01230866
Message ID:
01231288
Vues:
17
>>>>>Trouble is, the District list is in the correct DESC order but the Zones table is higgledy-piggledy order.
>>>>>
>>>>>Any ideas what's amiss?
>>>>
>>>>"DESC" as descending or description?
>>>>
>>>>And I'm not quite sure what do you mean by master-child here... do you mean the grids' recordsources are zones and districts respectively, and you got the county related into each (additive)? And if so, related via what field?
>>>
>>>Thank you (the only one who's answered)
>>>
>>>As I said, the DESC (Description) field of each table (not my table design)
>>>
>>>Belay what I said aboutn reversing the master [parent] - child order. I though I had but hadn't.
>>>
>>>Grid 1 has:
>>>- recordsource = ZONES
>>>- LinkMaster = COUNTY
>>>- ChildOrder = County (FK to COUNTY.Code - PK)
>>>- RelationalExpre = Code
>>>and if we look at the reln. arc's props in the DE:
>>>- ChildAlias = ZONE
>>>- ChildOrder = County
>>>- ParentAlias = COUNTY
>>>- RelationalExpre = Code
>>>
>>>Grid 2 has:
>>>- recordsource = DISTRICT
>>>- LinkMaster = COUNTY
>>>- ChildOrder = County (FK to COUNTY.Code - PK)
>>>- RelationalExpre = Code
>>>and if we look at the reln. arc's props in the DE:
>>>- ChildAlias = DISTRICT
>>>- ChildOrder = County
>>>- ParentAlias = COUNTY
>>>- RelationalExpre = Code
>>>
>>>So they both have similar key names and same relnship with COUNTY table. I have them both ordered on their DESC fields, so the descs appear in the grid in alphbetical order. Now this works (or seems to - maybe just luck) for the DISTRICT table but the ZONES table appears in random order, but the underlying table in the DE shows them to be in County (FK) order.
>>>
>>>Now I realise this is the ChildOrder, but when I set the Order prop, in the DE, to DESC I assumed the table would display in that order but I find the County FK is overriding.
>>>
>>>Maybe I'll have to make a composite key of County+Desc, but that won't have a matching parent index in the COUNTY table./
>>>
>>>IOW I want to display all the ZONEs for a particular COUNTY, but I want those zones in the grid, in their DESCription field order. I think it IS just luck that the DISTRICT table is in the right order.
>>
By using separate cursors for each grid (no relation,linkmaster etc) you can show data in any order and allow user to re-sort it interactively, etc.
Edward Pikman
Independent Consultant
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform