El_Pablo Posted August 11, 2010 Share Posted August 11, 2010 Hi, I'm new to charting. I've been trying to create a bar graph to show average sale price per quarter for houses. I've done the following relationships : analysis (pkAnalysis, ...) elements (pkElementID, fkAnalysis, fkSaleID, ...) sales (pkSaleID, price, quarter, ...) The layout is on analysis. How can I do bar chart using the quarter for the X-axis and the average price per quarter for the y-axis? Thanks Link to comment Share on other sites More sharing options...
Matthew F Posted August 12, 2010 Share Posted August 12, 2010 What happens if you insert a chart on the layout and designate the fields of your choice to the x and y axes? Link to comment Share on other sites More sharing options...
El_Pablo Posted August 12, 2010 Author Share Posted August 12, 2010 The X-axis doesn't merge the quarters together. Here is the resulting graph. Uploaded with ImageShack.us Link to comment Share on other sites More sharing options...
El_Pablo Posted August 12, 2010 Author Share Posted August 12, 2010 Anyone? Will I need to create a quarters table? Makes non sense to me. Since we should be able to group sales per quarter. Link to comment Share on other sites More sharing options...
El_Pablo Posted August 12, 2010 Author Share Posted August 12, 2010 Here is an example file with some sample data. forumInspection.zip Link to comment Share on other sites More sharing options...
Matthew F Posted August 13, 2010 Share Posted August 13, 2010 In your example file the problem has nothing to do with charting per se, it is a calculation error. Your calculated field would not show the average values in a portal either. You need to create a calculation or a relationship that aggregates the records by quarter. As it stands, your calculation averages all of the prices regardless of quarter. Link to comment Share on other sites More sharing options...
El_Pablo Posted August 13, 2010 Author Share Posted August 13, 2010 Ok, so you say that I'll need a quarter table related to the analysis table? If the database is for a chain store. How would I then filter out the sales per store per quarter? Would I need to create another relationship? Link to comment Share on other sites More sharing options...
Matthew F Posted August 15, 2010 Share Posted August 15, 2010 I think there is more than one way to compute averages, including setting up a new relationship. Your attachment was complicated and I didn't understand what it was trying to achieve so I simplified just to illustrate an approach with a new table/relationship. My guess is that, if you can get the calculation working in a portal it will work in a graphic as well. Matthew forumInspection.fp7.zip Link to comment Share on other sites More sharing options...
Recommended Posts
This topic is 5012 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now