November 2, 201015 yr Hi, I have the following tables: Visits[VisitID,PatientID] Prescriptions [VisitID,DrugId,Amount] DrugDetail [DrugID,DrugName,Category] On the "Visits" layout I am trying to put a chart that on Axis X will show the drug Category, and on Axis Y the total amount for that category.. I've been trying for hours with all the possible combinations but all my efforts didn't help Any suggestion?
November 2, 201015 yr This is not a charting problem. Unless you define some additional relationships and calculations, you cannot see sub-summarized child (Prescriptions) data from the parent (Visit) record. It's much easier to produce such chart on a layout of Prescriptions.
November 2, 201015 yr Author Hi, tnx or your reply. I know it is easier on the prescription layout...but I need it on the Visits layout...that is the problem. I tried to define all sort of relationships and calcs but still to no use... what am I missing with this chart?
November 2, 201015 yr What do you want to do with categories for which the total is zero? Do you want to display them as zero, or omit them altogether?
November 2, 201015 yr See the attached for one way to look at it. In your situation it might be best to lookup the category into the prescription, otherwise you'll need more relationships. Another option is to script the process and trigger the script on record load. Or perhaps use a custom function along the lines of: http://www.briandunning.com/cf/894 The bottom line here is that you cannot chart data that you cannot display. SubSummarizeChildUgo.zip
Create an account or sign in to comment