473,651 Members | 3,007 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Help!! - report to show gpas between dates

12 New Member
I have a database where a record has a start date and an end date and is linked to an employee.

Ho do I create a report that will show each employee and gaps between the employees next record start date and end date?

Many thanks, a confuesed Adrian :confused:
Jul 7 '06 #1
5 2486
sashi
1,754 Recognized Expert Top Contributor
Hi there,

below is a simple sample SQL statement dealing with dates.. good luck my fren.. :)

Expand|Select|Wrap|Line Numbers
  1. cmd = _
  2. "SELECT * FROM tData WHERE StationID LIKE '*BOOM*'" & _
  3. "  AND UserID = '" & cmbUserID & "'" & _
  4. "  AND DTG > #" & strStartDate & "#" & _
  5. "  AND DTG < #" & _
  6.      Format(DateAdd("d", 1, strEndDate), "short date") & "#" & _
  7. "ORDER BY DTG;"
  8.  
Jul 7 '06 #2
comteck
179 New Member
All you have to do is create a query with the table that has the date values. Drag down into the query the fields you want on the report. Of course, the date would be one of them.

Then, in the "Criteria" box for the date, type the following:

Between [Enter Start Date] And [Enter End Date]

This will prompt you to enter a start date and an end date. Of course, in the table, the data type for this date should be "Date/Time". Make sure you check that.

Lastly, in your report, open the properties, and select this query as the Record Source.

Good Luck.
comteck
Jul 9 '06 #3
AdrianE
12 New Member
I've created the query which prompts me for the 2 dates but shows all records not just gaps?

E.g. employee will repeat as many times as there are records but doesnt highlite that there is say a one day gap inbetween record 3 and 4 for that employee?? :confused: :confused: :confused:
Jul 11 '06 #4
comteck
179 New Member
Sorry. I think I misunderstood what you were asking. And now, I'm confused. I don't quite get what you're saying about the "gap". Could you be more specific, and maybe include some data to give a better idea of what you're asking.

Thanks.
comteck
Jul 12 '06 #5
AdrianE
12 New Member
E.g. table Employees: ID, Name, Address etc

Table Vehicles: Reg, Make, Model

I now enter mileage and start to end dates as Entry fields in a table with lookup values of one "vehicle" and one "employee", e.g "003" "Jo Bloggs" drove "VK03 XXX" between "4/04/06" and "12/04/06".

next entry for same employee was "17 April" to "20th April".

I need to somehow distinguish that for any employee ID if there are any gaps. In the instance of "003" " jo Bloggs" there is no record covering dates 13/04/06 to 16/04/06 and possible many more depending on how many enteries?

:confused:
Jul 26 '06 #6

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

Similar topics

2
13442
by: Sam | last post by:
Hello everyone, I have a table, which contains a picture column, I put URL info into it. "www.myweb.com/1.jpg..." I want to show this picture in my crystal report, I find some samples show the "static" picture in Crystal report, No "Dynamic" one. Can Crystal Report do that? Thanks in advance. Sam
6
1950
by: christopher.secord | last post by:
I have a table containing typed log entries. One log entry is supposed to be created every twelve hours, but sometimes there are gaps. I need to create a report showing the time of entry, and the actual log entry. I can't just list the contents of the log table, because if I do that there will be dates missing. Instead, when there isn't a log entry for a date, I need to print the date, and then just leave the log entry blank. The SQL...
1
2671
by: Dalan | last post by:
I'm developing a report selection form and one of the elements of design is providing Date from/to text boxes. I have a Table that contains all of the information regarding the reports and did create a column for assigning a value if dates are required for the reports (1=yes, -0=no). Need to know what code to use and where to allow this feature to be used on the report selection form and to have the Date from/to boxes appear only if in...
4
1736
by: Alicia | last post by:
I am having a problem grouping by week. I am looking for the simpliest way of doing it in Microsoft Access. I have tried to use a pre-loaded calender, access did not like it at all. If there is another way of counting the number of ProblemCounts with a single week, by using DatePart etc. Give me a shout. Thanks. Something similar to Before:
5
3503
by: Irfan | last post by:
Hi All, I am trying to create a report but having problem with the critiera selection logic, please help. I have the following fields date1 date2 date3
1
2238
by: josecruz | last post by:
I have to create a summary report that will provide counts and # average of days for multiple "Status" by entering different dates for every criteria. I have created several queries that calculates the number of days and the counts. I have created the corresponding report to show the sum and verages. But I don't know how to make them print on a main report that will display the information of multiple status since I have to enter multiple...
5
1592
by: hwt | last post by:
Hi Please excuse my poor description of the task. I have to make a report for my database. I need to have a report for each month. I need to make it so that each report contains every weekday of the month and places the results into a table, which has 7 columns. The other 6 columns need to provide a True/False grid based on the column titles(Session Names), which are the same on all reports. The True/False part needs to be filled in...
3
2147
by: mlcampeau | last post by:
Hi guys, I am trying to run a query that calculates when employees become eligible for supplemental vacation. This occcurs once the employee has reached 5, 10, 15, etc years of service. I got the query running great, it shows the correct dates, (5, 10, etc years after the HireDate) but I just found out that they don't want to know the exact anniversary date. People become entitled to their vacation January 1st of the year of their anniversary...
0
8278
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8807
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8466
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8584
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7299
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5615
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4144
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
1912
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1588
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.