Forum Discussion
Seanarm1234
May 05, 2023Copper Contributor
Integrity in my tables
I am making a database for a veterinary clinic. when entering data into the appointments table, I need it to limit what can be entered for PetID based on CustomerID so that pets aren't listed with the wrong owners. Any Suggestions?
- XPS35Iron Contributor
Seanarm1234 There is no need to store the customerID in the appointment table. If you just store the petID, you can find the customer through the pet table. You can show the customer on the appointment form and use that to find a pet for a new appointment. Search for "cascading comboboxes" to find examples.
One more point. What if a customer wants to make an appointment for two or more pets?