Relationship query

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello all! I am having difficulty deciding what type of relationship i should
give between 2 tables. The table names are 'employees' and 'payslip'. Below
is the list of fields in these tables:
TABLE EMPLOYEES: PK empid, empname,emp address, emp hourly wage ect....
TABLE PAYSLIP: PK PaylsipID, payslip date,empid, hours worked,

My question is regarding the relationship between empid to empid for the two
tables. The payslip table will act as a table to store payslips for different
dates and store employeeids as a way off knowing which employee has been paid
what amount each month. Which type of relationship do i need from the empid
from the employees table to teh empid in the payslip table. Do i need a
1-many from the employees table(empid field) to the payslip table(empid
field) or a 1-many from the payslip table(empid field) to the employees
table(empid field)????

All help would be great :)
 
You need a 1-many from the employees table(empid field) to the payslip
table(empid field) as for every one employee there will be many payslips.
 
thanks for the help karl, spot on!!!! have a nice day :) ur help has been
highly appreciated.
 
Ben said:
Hello all! I am having difficulty deciding what type of relationship i should
give between 2 tables. The table names are 'employees' and 'payslip'. Below
is the list of fields in these tables:
TABLE EMPLOYEES: PK empid, empname,emp address, emp hourly wage ect....
TABLE PAYSLIP: PK PaylsipID, payslip date,empid, hours worked,

My question is regarding the relationship between empid to empid for the two
tables. The payslip table will act as a table to store payslips for different
dates and store employeeids as a way off knowing which employee has been paid
what amount each month. Which type of relationship do i need from the empid
from the employees table to teh empid in the payslip table. Do i need a
1-many from the employees table(empid field) to the payslip table(empid
field) or a 1-many from the payslip table(empid field) to the employees
table(empid field)????

All help would be great :)

Ask yourself, "Does one employee have many payslips, or does one payslip
have many employees?"

Does this help?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Help Plz... 4
Need Help... 4
Date overlap***UP*** 1
Using Bound Control right 3
Need lookup field on a form- 2007 3
UNION query 11
Query Input 1
Record Review Process 2

Back
Top