Hi John,
Thanks for responding. It sounds like I may be in over my head. I'll tell
you what I have and what I am trying to do. My tables along w/fields are:
Employees - (First Name, Last Name, Dept Seniority, Job Seniority, & Hire
Date);
This table should certainly have a Primary Key, probably a numeric EmployeeID.
You cannot count on names to be unique. I'd also recommend avoiding blanks in
fieldnames - e.g. FirstName instead of First Name.
Service Record - (Dept. Name, job Title Name, Date In, & Date Out);
Is this a service record *for an employee*"?? If so, you need some way to tell
WHICH empployee, such as the employeeID.
Department Service - (Dept. Name & Service Time);
Is this a table of unique departments, or - again - service for the employee?
How is this table related (logically, based on the data in it) to the Service
Record table?
Job Title Service - (Job Title Service & Service Time)
Same questions.
I created a form. "Employees" is the main form. "Service Record" is my
subform shown in a tab. I have two other tabs - Department Service and Job
Title Service.
It really sounds like you started your design with the Forms. That's
backwards. You need to get the Tables right FIRST, and then create forms as
windows onto the tables!
I am trying to track an employee's service time within each department and
each job title. I was using the Department Service and Job Title Service
tabs as a means to keep a running total of time in each Department/Job Title.
Can you steer me in the right direction to accomplish this? Thanks again!
If you're using the "TABS" as a way to keep track... that's your first
problem. Forms *do not contain any data*. Forms are just tools, windows that
let you see and edit data which is stored in tables, and only in tables.
It's not clear to me what "service time" is, but if it is (or can be)
calculated from the date in and date out, then it should not be stored AT ALL,
in ANY table; it can instead by calculated on the fly in a Query.
My GUESS - and it's purely a guess, since I don't know your business - is that
you need four tables (for this portion of the application anyway):
Departments <just a lookup table for departments>
DepartmentID
DepartmentName
Jobs
JobID
JobDescription
Employees
EmployeeID <Primary Key; maybe autonumber, maybe tax ID, a unique identifier>
LastName
FirstName
HireDate
<other biographical info as needed>
JobHistory
JobHistoryID <autonumber primary key>
EmployeeID <whose history is this>
DepartmentID <which department were they in at this time>
JobID <what job were they doing at this time>
StartDate <date/time>
EndDate <date/time, NULL if they're still in the job>
Time in service, seniority, etc. can probably all be calculated dynamically
from the data in the job history table.