🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.cppbuilder.database.multi-tier
1 messages
1 total messages Started by Sean Hannan Fri, 14 Dec 2001 05:41
How do I use TTable's to create relationship?
#386
Author: Sean Hannan
Date: Fri, 14 Dec 2001 05:41
51 lines
2195 bytes
I have the following 4 Foxpro DBF data files.

Jobs
JOBNUM		CHARACTER	20
...
Primary index: JOBNUM

JobSections
JOBNUM		CHARACTER	20
SECTNUM	CHARACTER	20
...
Primary index: JOBNUM + SECTNUM
Secondary Index: JOBNUM

Claims
JOBNUM		CHARACTER	20
CLMNUM		NUMERIC	3
...
Primary index: JOBNUM + STR(CLMNUM, 3, 0)

ClaimSections
JOBNUM		CHARACTER	20
CLMNUM		NUMERIC	3
SECTNUM	CHARACTER	20
...
Primary index: JOBNUM + SECTNUM + STR(CLMNUM, 3, 0)
Secondary index: Primary key: JOBNUM + STR(CLMNUM, 3, 0)

Linking the Job Sections file to the Job file as well as linking the 
Claims file to the Jobs file is simply a matter of using the JOBNUM field 
so I can accomplish this ok.

At design time I am trying to use the MasterSource/MasterFields 
properties to set up a relationship between these 2 files using a 
combination of the JOBNUM/CLMNUM.  When I click on the "..." for the 
MasterFields, I am only allowed to choose from the 2 indexes for the 
ClaimSections file (as shown above) and a single field from the Claims 
file which gives me

JOBNUM + STR(CLMNUM, 3, 0) -> JOBNUM

which does not appear to give me the link I need.

Am I going about this entirely the wrong way or is there something else I 
should be doing in order to give me the link I am after.

Any help would be greatly appreciated.

Thanks in advance

Sean Hannan
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads