Results 1 to 3 of 3
  1. #1
    Access99 is offline Novice
    Windows 10 Access 2010 64bit
    Join Date
    Mar 2019
    Location
    Oregon
    Posts
    2

    How to create a query that supports this series graph

    Hello,
    I am trying to create an access graph in a Form.

    The objective is to have a line-graph as a time series as shown below.
    The issue I am having is that the data for facts is summed by the graph but I just want each value for each date to be a discreet point on the graph. Basically, I'd like a series line graph with dates at the bottom, the series = Industry names and data (or facts) to be the percent strength for that date.

    What the line-graph should look like.

    %
    .05...x....z....z....y....y....x....z....z
    .04...y....x....y....z....x....y....x....z
    .03...z....y....x....x....z....z....y....x
    .02.........z....y....y....x...............

    ......3/1.3/5.3/7.3/9.3/10.3/11.3/12.3/13

    Legend
    x = Information Technology (Industry)
    y = Utilities (Industry)
    z = Health Care (Industry)

    Current data
    Date....Industry.....................PctStrngth
    3/1.....Information Technology......5%
    3/1.....Utilities............................4%
    3/1.....Health Care.......................3%
    3/5.....Information Technology........4%
    3/5.....Utilities.............................3%
    3/5.....Health Care.......................5%
    3/7.....Information Technology........3%
    3/7.....Utilities.............................2%
    3/7.....Health Care........................5%
    ETC.

    What I think the data needs to look like or perhaps Access can't do this.
    ........Information Technology.....Utilities.....Health Care


    3/1................5%......................4%....... .....3%
    3/5................4%......................3%....... .....5%
    3/7................3%......................2%....... .....5%
    ETC

    Thank you. Hopefully, Access can create such a graph.

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,926
    A CROSSTAB query can get the output you show. The Graph wizard will build line chart and construct the query for you. It will want to group on month/yr but you can modify the SQL after the chart is created.

    TRANSFORM Sum([PctStrngth]) AS [SumOfPctStrngth]
    SELECT [Date]
    FROM [Table1]
    GROUP BY [Date]
    PIVOT [Industry];

    If you need to filter the query to a year, use PARAMETERS. Review http://allenbrowne.com/ser-67.html
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    Access99 is offline Novice
    Windows 10 Access 2010 64bit
    Join Date
    Mar 2019
    Location
    Oregon
    Posts
    2
    June 7 - thank you for your help. That solved the issue I was having.
    I really appreciate it.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 6
    Last Post: 10-09-2015, 12:06 PM
  2. Replies: 24
    Last Post: 07-28-2015, 10:50 AM
  3. Replies: 6
    Last Post: 02-29-2012, 03:13 AM
  4. Replies: 3
    Last Post: 01-10-2011, 10:31 AM
  5. Replies: 0
    Last Post: 07-22-2010, 07:43 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums