LizzieR
08-17-2010, 03:57 AM
I wonder if anyone can help me? Please forgive the long explanation below, i've been working on this for a few days, and finally I think I know the question I need to ask!
I'm creating a database from an existing dataset. Unfortunately i'm not able to interrogate it directly, so I have to extract the data and load it up into Access to run my queries. I have been doing this using Excel and am just reaching the limit of manipulating the data.
The data is finance and project information for a set of projects, my business needs are to assess individuals' performance by accumulating info from several projects, and track finance by project or person or location. The structure I am thinking of is as follows:
tblProjects - this info will be unique to the project
Project Number - this is a unique identifier
External partner (this is the original partner and doesn't change)
External reference
tblProjectinfo - this links the project personnel to the project
ID (autonumber field which i will insert on uploading the data)
Project Number (link to tblProjects)
Person name
Personnel number (this can't find the name in a "people" table, as people sometimes have more than one personnel no, so it has to be specific to that project)
Role in the project
Person Location ID (again, needs to be specific to project)
Then I have a load of financial info for each project that has to be in 3 separate tables. These are organised by the same records as tblProjectinfo, so each person working on a project will have a record in each of 3 tables of financial data, specific to that project/person/location/role profile. This will look like:
TblFinance1
Project No
Person name
Personnel number
Role in the project
Location ID
Expenditure2010Q1
Expentidure2010Q2
...and so on
Initially i thought each personnelNo/projectID combination could function as a composite key. However as I investigated the data, the same person can be listed more than once in the same project, either in >1 role, or >1 location, or both.
(So, to clarify, if person A is listed twice on one project in different locations or roles, the existing system should spit out 2 sets of financial records, as if 2 separate people.)
My question is: when i download the finance info from the system, i would like to link it to tblProjectInfo so I can query the finances by person. The only way I can think of doing this is to make a big composite key of projectID/PersonnelNo/Location/Role and relate this to the equivalent key in each of the the finance tables. Is this a terrible idea? Is there a better way of doing it?
I really appreciate any advice you can give. I hope i've given enough info, but if not please ask and I will try to clarify.
I'm creating a database from an existing dataset. Unfortunately i'm not able to interrogate it directly, so I have to extract the data and load it up into Access to run my queries. I have been doing this using Excel and am just reaching the limit of manipulating the data.
The data is finance and project information for a set of projects, my business needs are to assess individuals' performance by accumulating info from several projects, and track finance by project or person or location. The structure I am thinking of is as follows:
tblProjects - this info will be unique to the project
Project Number - this is a unique identifier
External partner (this is the original partner and doesn't change)
External reference
tblProjectinfo - this links the project personnel to the project
ID (autonumber field which i will insert on uploading the data)
Project Number (link to tblProjects)
Person name
Personnel number (this can't find the name in a "people" table, as people sometimes have more than one personnel no, so it has to be specific to that project)
Role in the project
Person Location ID (again, needs to be specific to project)
Then I have a load of financial info for each project that has to be in 3 separate tables. These are organised by the same records as tblProjectinfo, so each person working on a project will have a record in each of 3 tables of financial data, specific to that project/person/location/role profile. This will look like:
TblFinance1
Project No
Person name
Personnel number
Role in the project
Location ID
Expenditure2010Q1
Expentidure2010Q2
...and so on
Initially i thought each personnelNo/projectID combination could function as a composite key. However as I investigated the data, the same person can be listed more than once in the same project, either in >1 role, or >1 location, or both.
(So, to clarify, if person A is listed twice on one project in different locations or roles, the existing system should spit out 2 sets of financial records, as if 2 separate people.)
My question is: when i download the finance info from the system, i would like to link it to tblProjectInfo so I can query the finances by person. The only way I can think of doing this is to make a big composite key of projectID/PersonnelNo/Location/Role and relate this to the equivalent key in each of the the finance tables. Is this a terrible idea? Is there a better way of doing it?
I really appreciate any advice you can give. I hope i've given enough info, but if not please ask and I will try to clarify.