Hi everyone,
Hopefully someone can help me.
In Table 1 - I have a set of contracts that have a unique number. However, although the primary key is the contract number - these numbers can be duplicated as long as their start and end dates don't overlap. So my question is, how do I make the Primary key the contract number plus the start and end date? Is this possible?
In Table 2 - I have a list of orders that relate to Table 1. i.e. Each order has a contract it relates to. How do I make sure that in a query, the order number picks up the correct contract for the corresponding date.
For example...
Table 1
Field 1: Contract Number
Field 2: Contract Start
Field 3: Contract End
Field 4: Contract Details
Table 2
Field 1: Order Number
Field 2: Order Date
Field 3: Contract Number
My query would pick up Order Number, Order Date, Contract Number, Contract Details.
Thanks in advance for any help folks,
Ross.
Hopefully someone can help me.
In Table 1 - I have a set of contracts that have a unique number. However, although the primary key is the contract number - these numbers can be duplicated as long as their start and end dates don't overlap. So my question is, how do I make the Primary key the contract number plus the start and end date? Is this possible?
In Table 2 - I have a list of orders that relate to Table 1. i.e. Each order has a contract it relates to. How do I make sure that in a query, the order number picks up the correct contract for the corresponding date.
For example...
Table 1
Field 1: Contract Number
Field 2: Contract Start
Field 3: Contract End
Field 4: Contract Details
Table 2
Field 1: Order Number
Field 2: Order Date
Field 3: Contract Number
My query would pick up Order Number, Order Date, Contract Number, Contract Details.
Thanks in advance for any help folks,
Ross.