B
Barry
I have 3 tables selected in a Query. Table 1 is clients, table 2 is
contacts, table 3 is reports. I want to retrieve names and addresses
from Table 1 and Table 2 based on data in Table 3. Table 2 and Table
3 each have a key field called ID and they are equal to one another.
Table's 3 key field of ID is a negative of Table 1's ID field (for
example, table 1 ID field=2000, Table 3 ID field=-2000), which is what
is giving me a problem. I can query the data by joining Tables 2 and
3 (since the ID's equal one another) but don't know how to do the same
thing with Table 1 and Table 3 (where the ID's are the negative of one
another). The access database comes from a program so it cannot be
changed. I'm assuming the reason for the negative ID's is that there
can be an ID from Table 1 that is the same in Table 2 even though they
are not related (Table 1 is a client, Table 2 is a contact, there is
another field in Table 2 that relates back to Table 1). Basically, if
the ID in Table 3 is negative, the names/addresses come from Table 1,
if the ID in Table 3 is positive, the names/addresses come from Table
2. Can anyone lead me in the right direction?
Barry
contacts, table 3 is reports. I want to retrieve names and addresses
from Table 1 and Table 2 based on data in Table 3. Table 2 and Table
3 each have a key field called ID and they are equal to one another.
Table's 3 key field of ID is a negative of Table 1's ID field (for
example, table 1 ID field=2000, Table 3 ID field=-2000), which is what
is giving me a problem. I can query the data by joining Tables 2 and
3 (since the ID's equal one another) but don't know how to do the same
thing with Table 1 and Table 3 (where the ID's are the negative of one
another). The access database comes from a program so it cannot be
changed. I'm assuming the reason for the negative ID's is that there
can be an ID from Table 1 that is the same in Table 2 even though they
are not related (Table 1 is a client, Table 2 is a contact, there is
another field in Table 2 that relates back to Table 1). Basically, if
the ID in Table 3 is negative, the names/addresses come from Table 1,
if the ID in Table 3 is positive, the names/addresses come from Table
2. Can anyone lead me in the right direction?
Barry