473,466 Members | 1,412 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Need help with graph

57 New Member
Hi,

I need to create a graph report that showed total hours and unattended hours based on certain months and operation code that user input into the form.
I have two queries:
one to calculate the total hours worked and the other is to calculate total unattended hours. I also have a form, where user input what months and what operation code that user wants to see on the graph.
now I need the graph to show on the primary axis is the total from total hours query and on the secondary axis is total from unattended hours query.
I can't combine the 2 queries together since it gave me duplicated total and unattended hours (that's why I have to seperate the query into 2). can we use two queries on the graph? Could you help me what is the best way to do this report? This is the first time I'm using graph.

Thank you
Jul 23 '07 #1
3 1775
ADezii
8,834 Recognized Expert Expert
Hi,

I need to create a graph report that showed total hours and unattended hours based on certain months and operation code that user input into the form.
I have two queries:
one to calculate the total hours worked and the other is to calculate total unattended hours. I also have a form, where user input what months and what operation code that user wants to see on the graph.
now I need the graph to show on the primary axis is the total from total hours query and on the secondary axis is total from unattended hours query.
I can't combine the 2 queries together since it gave me duplicated total and unattended hours (that's why I have to seperate the query into 2). can we use two queries on the graph? Could you help me what is the best way to do this report? This is the first time I'm using graph.

Thank you
Post the SQL from the 2 Queries. How are the values for Month and Operation transferred to the 2 Queries?
Jul 23 '07 #2
ConfusedMay
57 New Member
Post the SQL from the 2 Queries. How are the values for Month and Operation transferred to the 2 Queries?
I have a form called selection that has 3 textboxes which are txtstartdate, txtenddate, and txtopcode for user to input the information.

here is the query to calculate the total hours: (I create regular query, but here is the SQL view):

SELECT labor_ticket.DATE, Sum(labor_ticket.HOURS_WORKED) AS SumOfHOURS_WORKED, Opcode.Department, Opcode.Opcode, (Format([DATE],"mm"" '""yy")) AS months_total
FROM LABOR_TICKET INNER JOIN Opcode ON LABOR_TICKET.RESOURCE_ID = Opcode.Opcode
GROUP BY LABOR_TICKET.DATE, Opcode.Department, Opcode.Opcode, (Format([DATE],"mm"" '""yy"))
HAVING (((LABOR_TICKET.DATE) Between ([forms]![selection]![Txtstartdate]) And ([forms]![selection]![Txtend])) AND ((Opcode.Opcode)=[([forms]![selection]![Txtopcode]))
ORDER BY LABOR_TICKET.DATE, Opcode.Department;

and here is the query to calculate the total unattended hours:

SELECT LABOR_TICKET.DATE , Sum(LABOR_TICKET.HOURS_WORKED) AS Unattended, Opcode.Department, Opcode.Opcode,(Format([DATE],"mm"" '""yy")) AS months_unattended
FROM LABOR_TICKET INNER JOIN Opcode ON LABOR_TICKET.RESOURCE_ID = Opcode.Opcode
WHERE (((LABOR_TICKET.EMPLOYEE_ID) Like "8*"))
GROUP BY LABOR_TICKET.DATE, Opcode.Department, Opcode.Opcode, (Format([DATE],"mm"" '""yy"))
HAVING (((LABOR_TICKET.DATE) Between ([forms]![selection]![Txtstartdate]) And ([forms]![selection]![Txtend])) AND ((Opcode.Opcode)=[([forms]![selection]![Txtopcode]))
ORDER BY LABOR_TICKET.DATE, Opcode.Department;

what I need is to create a chart report that consists total hours and total unattended hours values. could we use 2 queries in the chart report? Please help.

Thank you so much
Jul 24 '07 #3
ConfusedMay
57 New Member
I have a form called selection that has 3 textboxes which are txtstartdate, txtenddate, and txtopcode for user to input the information.

here is the query to calculate the total hours: (I create regular query, but here is the SQL view):

SELECT labor_ticket.DATE, Sum(labor_ticket.HOURS_WORKED) AS SumOfHOURS_WORKED, Opcode.Department, Opcode.Opcode, (Format([DATE],"mm"" '""yy")) AS months_total
FROM LABOR_TICKET INNER JOIN Opcode ON LABOR_TICKET.RESOURCE_ID = Opcode.Opcode
GROUP BY LABOR_TICKET.DATE, Opcode.Department, Opcode.Opcode, (Format([DATE],"mm"" '""yy"))
HAVING (((LABOR_TICKET.DATE) Between ([forms]![selection]![Txtstartdate]) And ([forms]![selection]![Txtend])) AND ((Opcode.Opcode)=[([forms]![selection]![Txtopcode]))
ORDER BY LABOR_TICKET.DATE, Opcode.Department;

and here is the query to calculate the total unattended hours:

SELECT LABOR_TICKET.DATE , Sum(LABOR_TICKET.HOURS_WORKED) AS Unattended, Opcode.Department, Opcode.Opcode,(Format([DATE],"mm"" '""yy")) AS months_unattended
FROM LABOR_TICKET INNER JOIN Opcode ON LABOR_TICKET.RESOURCE_ID = Opcode.Opcode
WHERE (((LABOR_TICKET.EMPLOYEE_ID) Like "8*"))
GROUP BY LABOR_TICKET.DATE, Opcode.Department, Opcode.Opcode, (Format([DATE],"mm"" '""yy"))
HAVING (((LABOR_TICKET.DATE) Between ([forms]![selection]![Txtstartdate]) And ([forms]![selection]![Txtend])) AND ((Opcode.Opcode)=[([forms]![selection]![Txtopcode]))
ORDER BY LABOR_TICKET.DATE, Opcode.Department;

what I need is to create a chart report that consists total hours and total unattended hours values. could we use 2 queries in the chart report? Please help.

Thank you so much
never mind I got it... Thank you....
Jul 25 '07 #4

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

Similar topics

5
by: Herman | last post by:
Hi everyone, I'm implementing Dijkstra's algorithm for a class project, and I'm having trouble compiling the class that runs the algorithm. All of the other files compile fine except for this one....
0
by: SS KANAGAL | last post by:
Hello, I am drawing a bar graph in an aspx page using System.Drawing namespace . Now I want to provide drill down facility for the graph i.e. on click of a bar in the graph it should get me yet...
1
by: mark.engelberg | last post by:
I am having trouble identifying the source of a memory leak in a Windows Python program. The basic gist is as follows: 1. Generate a directed graph (approx. 1000 nodes). 2. Write the graph to a...
2
by: Jeff Blee | last post by:
I am hoping someone can help me. I am making a Access 97 app for a person and have run up against a problem to do with MS Graph. There is a table that has a number of data elements and a date field...
1
by: entropy123 | last post by:
Hey all, In an effort to solve a sticky - for me - problem I've picked up Sedgewick's 'Algorithm's in C'. I've tried working through the first few problems but am a little stumped when he refers...
7
by: Bigs | last post by:
Ok, I have been working on a Linear Equation program that will draw a line on my graph. But, I am not sure how to set up the y=mx+b in Java to return the (x1,y1) and (x2, y2) using only the slope and...
2
by: huiling25 | last post by:
I was given the pseudo code.. but i still cannot figure out how to do it... how can i find if the vertices are adjacent to the vertex on stack top? I know i have to have an array of true/false (to...
2
by: sriniwas | last post by:
Hi Frnd's, m using prefuse visulation,it's have one display class and this class have one saveImage(outPutStream, String jpg,double size);. now graph is converting ia jpg image properly.now my...
7
thatos
by: thatos | last post by:
Here is the EdgeList class class Graph { protected int numvertices; protected int numedges; protected boolean directed; protected EdgeList adjlist ; // Constructors
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.