By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,426 Members | 2,928 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,426 IT Pros & Developers. It's quick & easy.

displaying values of table on graph

P: 86
hello friends,
i have a table.
the table columns change from time to time.
i.e they are not constant.
colums may increase or decrease.

i want to show the values of these table on a Area graph.
if the columns are constant it would be easy. but since the columns are variable, i am unable to build graph.
how can i display the values of such tables on graph?

i am sure that one coloum will be permanent. and all other columns will keep changing.
kindly if any body knew, please suggest me the approach

Oct 18 '07 #1
Share this Question
Share on Google+
3 Replies

Expert 2.5K+
P: 3,072
Guess you'll need to transform the fields with a UNION into columns.
So having a three table column:
Expand|Select|Wrap|Line Numbers
  1. ID
  2. Field1
  3. Field2
Would require:
Expand|Select|Wrap|Line Numbers
  1. select ID, "Field1" as Origin, Field1 from tblYours
  2. UNION
  3. select ID, "Field2" as Origin, Field2 from tblYours
This will allow you to create a graph with the Origin as series.

Getting the idea ?

Oct 18 '07 #2

P: 86
thank you for your response.

i am still not clear.

i have a column "Year" that is permanent in that table(i.e, values in that column may change but the column will not be deleted forever).
the other columns may deleted are some more may be appended to the table.
so they vary.

now i want a area graph and a bar graph that displays "Year" as x-axis/y-axis and the remaining column values on the other axis. i.e every column values will be displayed in seperate colour.

i am not good at graphs.

how how can i do this?
Oct 19 '07 #3

Expert 2.5K+
P: 3,072
Basically you'll need to store the data in a format like:

Year, NameOfValue, RealValue
2007, Measurement1, Blue
2007, Measurement2, 234
2007, Measurement1, Red

Thus when you have a table with Year, Measurement1, Measurement2 you'll need the proposed UNION query from my previous post to get the data available in the format from the sample here.
Just take one of your tables with a year and two fields and create the UNION query. Then use that query for creating a graph to see the effect.
The variable number of fields is another issue we can deal with later.

Oct 19 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.