473,396 Members | 1,777 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

run report using three criterias

rcollins
234 100+
I have a database where I keep track of services and service types. Also i have to keep track of the time that three people spend at each of these services. The accountant would like it to read like this:
Expand|Select|Wrap|Line Numbers
  1.           person1          person2         person3         total
  2.           :45                 :30                :00                 1:15
  3.           :15                1:00               :15                 1:30
  4. total   1:00               1:30               :15                 2:45
Any help would be greatful
Dec 22 '06 #1
11 1556
MMcCarthy
14,534 Expert Mod 8TB
I have a database where I keep track of services and service types. Also i have to keep track of the time that three people spend at each of these services. The accountant would like it to read like this:
person1 person2 person3 total
:45 :30 :00 1:15
:15 1:00 :15 1:30
total 1:00 1:30 :15 2:45
Any help would be greatful
Can you post a reply to this thread on Wednesday/Thursday to bump it up the list. It may not get much attention over Christmas.

Happy Holidays.

Mary
Dec 25 '06 #2
Killer42
8,435 Expert 8TB
I'm just re-posting the question with [c o d e] tags to preserve the formatting, as it doesn't show up in the original...
I have a database where I keep track of services and service types. Also i have to keep track of the time that three people spend at each of these services. The accountant would like it to read like this:
Expand|Select|Wrap|Line Numbers
  1.           person1          person2         person3         total
  2.               :45              :30             :00          1:15
  3.               :15             1:00             :15          1:30
  4. total        1:00             1:30             :15          2:45
(Actually, I had to shuffle things around a bit to line up in the non-proportional font.)
Dec 27 '06 #3
Killer42
8,435 Expert 8TB
Now that I actually come to read the question, can you be more specific as to what part(s) you need hep with? I think most of us will find the request too vague, so far.
Dec 27 '06 #4
rcollins
234 100+
Person1, person2 and person3 are all from the same dropdown list.As you can see, the accountant wants it to look more like a spreadsheet rather than a report. How do I get the report to put all three on the same line rather than under each other? Also, I have to calulate the times across and down and am not sure how to do that. If you would rather email me, rcollins at mds dot acsol dot net. Thanks
Dec 28 '06 #5
acoder
16,027 Expert Mod 8TB
Also, I have to calulate the times across and down and am not sure how to do that. If you would rather email me, rcollins@mds.acsol.net. Thanks
Calculating the totals could be done via a mod function or similar so that 60 mins. equals 1 hour, so, e.g. 75 mins would equal 1:15 (75 mod 60 : 75 rem 60). Not exactly sure how that's done in Access, but if you can find modulus and remainder functions, you should be on the right track.

Don't ask to be emailed because that's a complete no-no on a forum.
Dec 28 '06 #6
Killer42
8,435 Expert 8TB
Mary, where are you when we need you? Personally, I think this sounds like a job for a crosstab query, but I'm not familiar with them.

Don't ask to be emailed because that's a complete no-no on a forum.
Also, placing your e-mail address on a forum (any forum) like this allows spammers to pick it up and flood you with spam. Not a good idea. If you must post it, try to obscure it in some way so that a person can tell what you mean, but software will have a hard time with it.
Dec 29 '06 #7
MMcCarthy
14,534 Expert Mod 8TB
Mary, where are you when we need you? Personally, I think this sounds like a job for a crosstab query, but I'm not familiar with them.

Also, placing your e-mail address on a forum (any forum) like this allows spammers to pick it up and flood you with spam. Not a good idea. If you must post it, try to obscure it in some way so that a person can tell what you mean, but software will have a hard time with it.
Sorry guys, I've been sick all week.

OK the crosstab would give you the person1, person2, person3 but not the total. First you will need to query it. To design the query I need to know the structure of the table. What is the name of the field with the person drop down list and what is the name of the field which stores the time? What is the name of the table? Also can a person have more than one time record (i.e.) does the time need to be sumed for each person?

Happy New Year!

Mary
Jan 1 '07 #8
rcollins
234 100+
Mary, sorry to here you were sick. And through the holidays.
Here is some info on the table.
table name = tblMain
fields:
ID-primary key
ClientID-client id number
Date
Title (3 titles to be split by, Line Staaf, Lead Therapist, Senior Therapist)-therapists
Service-category of service
ServiceType-detail ofservice
Time
We will run a report at the end of the month to get total time spent whith each and the client can have time with all three people. What they would like to see is the total of time for the month that each client spends with each person, and a total for each person and the time spent with all clients. I do know a little about crosstabs, but not enough to pull this one off. Let me know what you think. Thanks so much
Jan 2 '07 #9
MMcCarthy
14,534 Expert Mod 8TB
Mary, sorry to here you were sick. And through the holidays.
Here is some info on the table.
table name = tblMain
fields:
ID-primary key
ClientID-client id number
Date
Title (3 titles to be split by, Line Staaf, Lead Therapist, Senior Therapist)-therapists
Service-category of service
ServiceType-detail ofservice
Time
We will run a report at the end of the month to get total time spent whith each and the client can have time with all three people. What they would like to see is the total of time for the month that each client spends with each person, and a total for each person and the time spent with all clients. I do know a little about crosstabs, but not enough to pull this one off. Let me know what you think. Thanks so much
Try creating a report based on the following and see where that leaves you.

Expand|Select|Wrap|Line Numbers
  1. TRANSFORM Sum ([Time]) As TimeSpent 
  2.  SELECT ClientID,  MonthName(Month([Date])) As MthName
  3.  FROM tblMain 
  4.  GROUP BY    ClientID,  MonthName(Month([Date])) As MthName
  5.  PIVOT Title;
  6.  
Mary
Jan 3 '07 #10
rcollins
234 100+
So far so good. You have some skills. I only had to modify it a little bit. Lets see about this one:
For example, on the report, the first client spent 2 hrs with linestaff, 4 hrs with lead therapist and 5 hrs with seior therapist. I have totals on the bottom of the report, but now would like to have totals for each client. So this one should be 11.
Jan 3 '07 #11
MMcCarthy
14,534 Expert Mod 8TB
So far so good. You have some skills. I only had to modify it a little bit. Lets see about this one:
For example, on the report, the first client spent 2 hrs with linestaff, 4 hrs with lead therapist and 5 hrs with seior therapist. I have totals on the bottom of the report, but now would like to have totals for each client. So this one should be 11.
Put an unbound textbox in the details section and set the control source to

Expand|Select|Wrap|Line Numbers
  1.  =[textbox1] + [textbox2] + [textbox3]
where textbox1 is linestaff total etc.

Mary
Jan 3 '07 #12

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

Similar topics

0
by: David | last post by:
This might be a report question but I think it is more a query issue than a report. I am a novice at bothAccess reporting and queries and have been struggling to build the following. (Note using...
2
by: Wolfgang | last post by:
Hi, I need to timestamp printed records with the printing date. According to the customer's requests the report must be opened in preview-mode and the user clicks on the printer button if he...
2
by: kabradley | last post by:
Hello everyone. I have three reports that I would like to put into one main report. I tried creating the main report and then putting three seperate subreports in the detail section of the parent...
12
by: Studiotyphoon | last post by:
Hi, I have report which I need to print 3 times, but would like to have the following headings Customer Copy - Print 1 Accounts Copy - Print 2 File Copy -Print 3 I created a macro to...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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
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
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
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,...

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.