Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Help with Report

Status
Not open for further replies.

debbieg

Technical User
Dec 2, 2002
190
US
I am in the process of creating a database that will track employees hours worked.

Here are my tables:

PayRate:
EmpNo
HomeDept
HourlyPayRate

HoursWorked:
EmpNo
WorkDate
RegHrs
OTHrs
Vacation
Sick
Holiday
etc.

OtherDeptWorked:
EmpNo
WorkDate
TempDept
TempDeptRegHrs
TempDeptOTHrs

I an needing to generate a report that shows the following:

Entry Home Reg O/T Temp Temp Temp
Emp No. Dept Hrs Hrs Dept RegHrs OTHrs
John 1 620 60 4
John 2 620 615 12 4
John 3 620 678 8
Mary 1 678 80
Sam 1 615 80

This report is for a 2-week period. The first entry for every employee will be calculated from the HoursWorked table. Additional entries for employees will be only if they have records in the OtherDeptWorked table. How do I generate the Entry No.?

Thanks in advance for any help/suggestions,
Debbie
 
If you want them sequential, try adding a couple formulas. First, group by employee. Then in the employee header record, create a formula like this:

Whileprintingrecords;
Global Numbervar EmpCount;
EmpCount := 0;

In your detail record (which is what I assume you are printing above), add another formula:

Whileprintingrecords;
GlobalNumbervar EmpCount;
EmpCount := EmpCount + 1;
Empcount

forgive me if there are syntax errors, I don't have Crystal loaded on this machine.
 
Sorry, thought we were in the Crystal Reports section.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top