Dear Sir/Madam,
I need help with access application database.
I have two tables with relationship one to many.
The 1st table is Tracking_Master and the the 2nd is Tracking_Detail.
The 1st table contain list of purchased material and the 2nd table contain tracking information of each purchased material in the 1st table.
1st Table (Tracking_Master) consist of fields: ID, MATERIAL_NAME, ORDER_QUANTITY, SUPPLIER, PURCHASE_ORDER_NO.
2nd Table (Tracking_Detail) consist of fields: ID, MATERIAL_NAME (Link to field "ID" in the 1st Table), TRACKING_CATEGORY, QUANTITY, NOTE
Field of TRACKING_CATEGORY in the 2nd table is a combo box contain selections of; EXPEDITING, RECEIVE_FROM_SUPPLIER, SOLD_TO_CUSTOMER.
How to make a form with conditions as below;
1. When the user input the tracking activity in the 2nd table, with category "EXPEDITING" then the field "QUANTITY" is disable.
2. When the user input the tracking activity in the 2nd table, with "RECEIVE_FROM_SUPPLIER" or "SOLD_TO_CUSTOMER" then the field "QUANTITY" is enable.
3. If the user input the quantity for tracking category RECEIVE_FROM_SUPPLIER and the total quantity is more then ORDER_QUANTITY in the 1st table then inform user and reject the inputted value (sometime user will input the tracking category of RECEIVE_FROM_SUPPLIER more then once, since we may receive the material partially from the supplier).
4. If the user input the quantity for tracking category SOLD_TO_CUSTOMER and the total quantity is more then the total quantity of tracking category RECEIVE_FROM_CUSTOMER then inform user and reject the inputted value (sometime user will input the tracking category of SOLD_TO_CUSTOMER more then once, since we may sold the material partially to our customer).
5. Each time the user input quantity for tracking category RECEIVE_FROM_SUPPLIER or SOLD_TO_CUSTOMER, the form count the balance order or the balance stock.
I attach my database to make you have a better understanding with my situation.
Thank you for your help.