populating table fields

M

Mike

I'm trying to populate fields in one table with data from another

say I have a table with employees in as follows

employeeID(primary key)
name
charge rate
trade

and say a table called labour

LabourID(primary key)
job record
name (selected on a lookup to the employee table)
charge rate (populated data from employee table once name had been
picked)
trade (populated data from employee table once name had been
picked)



Any help would be great



Mike
 
J

John Vinson

I'm trying to populate fields in one table with data from another

say I have a table with employees in as follows

employeeID(primary key)
name
charge rate
trade

and say a table called labour

LabourID(primary key)
job record
name (selected on a lookup to the employee table)
charge rate (populated data from employee table once name had been
picked)
trade (populated data from employee table once name had been
picked)

You're missing the point of how relational databases work.

They're based on the "Grandmother's Pantry Principle" - "a place - ONE
place! - for everything, everything in its place".

The Labour table should contain the EmployeeID as a link to the
Employee table - AND NOTHING ELSE from the Employee table. Storing the
name, the charge rate, or the trade redundantly is neither necessary
nor beneficial.

If (as it appears likely) you're trying to enter data directly into
the Labour table datasheet - don't. Table datasheets are of VERY
limited value for anything other than design and debugging. Instead,
create a Form based on Employees, with a Subform based on the virtuous
and loyal labour of the horribly exploited workers... <oops, my
politics are showing...>

John W. Vinson[MVP]
 

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

Top