Hello everyone,
Here is the scanario:
Tables:
T_Physicians
fields: (pk)TaxID, PhysicianName
T_ServiceCodes (I have 3 of these tables)
fields: (pk)Servicecode, ServiceName, Price
Mission:
Associate each TaxID to each ServiceCode, mind you, each Physician have their own Service codes that they bill.
Should I build a Query with a Criteria to find it in 1 Table or Build Separate lookup ServiceCodes table to reference each TaxID in T_Physicians table?
Enclosed is the SQL code of my QUERY;
What i'm trying to accomplish is this: say for example the Physician TaxID is equal to Sibley Hospital, I would like a means to automatically reference the SibleyCPT table inorder to choose my Sibley service codes and prices each time the specified TaxID is selected.
SELECT T_Service.ServiceNumID, T_Service.TaxIDNum, T_Physicians.TaxID, T_Physicians.HospitalName, T_Service.SibleyNum, T_SibleyCpt.CPTcode, T_SibleyCpt.Charge, T_Service.ECCcptNum, T_ECCcpt.CPTcode, T_ECCcpt.Charge
FROM T_SibleyCpt INNER JOIN (T_Physicians INNER JOIN (T_ECCcpt INNER JOIN T_Service ON T_ECCcpt.ECCcptNum = T_Service.ECCcptNum) ON T_Physicians.TaxIDNum = T_Service.TaxIDNum) ON T_SibleyCpt.SibleyNum = T_Service.SibleyNum;
Please Help
thank you in advance
---adigga1