Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Set Relation To ?
Message
De
09/05/2003 08:39:04
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
09/05/2003 08:25:37
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00786709
Message ID:
00786716
Vues:
18
>I am new to VFP and I have question on SET RELATION TO command/usage in context of application I've inherited.
>
>There is an .SCX (form) with following code in Load() method.
>
>SET RELATION TO ra_dcn INTO dd_dwgh IN dd_ecrapp
>
>dd_dwgh, and dd_ecrapp are database tables in app db.
>
>ra_dcn is field and index in dd_ecrapp table.
>
>My ?: How does it know which specific index field to relate to
>in dd_dwgh.
>
>The Primary key (index) for dd_dwgh table is DH_DCN. Both
>dd_ecrapp.RA_DCN and dd_dwgh.DH_DCN are integers.
>
>Am I corect in assuming that the dd_dwgh as child table gets
>its' PK field picked up by default for relation?
>
>Fred Z


It doesn't relate to a specific field. It relates to active index in child table (dd_dwgh). If there is no active index then relation is directly to recno() of child.

If dd_dwgh has no active index (ra_dcn integer) then each ra_dcn value is pointing to record#ra_dcn in dd_dwgh

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
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform