If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
New Database Design
I need to create a database that tracks the purchases of employees. Here are
some details: 3 employees buy auto parts, tools and office supplies for a maintenance shop. I would like to track the employee, purchase details, vendor used and catagorize the purchase as either tools, auto parts, tires or office supplies. Then quarterly our RA will run a query to print a report that show how much has been spent on the different catagories. I know I will need tables for: employees, catagories, purchase details and invoices. Does this seem correct? Does anyone have any suggestions for a better design? Will I need a junction table? Thanks. -- Ron A. |
#3
|
|||
|
|||
New Database Design
Ron,
I would suggest you look at the Northwind database that should help you in determining tables needed. (At fist glance, I see you didn't mention a tblVendors and tblInventory.) You didn't mention whether or not this is your first database. If it is have a look at... Jeff Conrad's resources page: http://www.accessmvp.com/JConrad/acc...resources.html The Access Web resources page: http://www.mvps.org/access/resources/index.html A free tutorial written by Crystal (MS Access MVP): http://allenbrowne.com/casu-22.html MVP Allen Browne's tutorials: http://allenbrowne.com/links.html#Tutorials http://www.databasedev.co.uk/table-of-contents.html You also might find some helpful data models here... http://www.databasedev.co.uk/data_models.html -- Gina Whipp "I feel I have been denied critical, need to know, information!" - Tremors II http://www.regina-whipp.com/index_files/TipList.htm "Ron A." wrote in message ... I need to create a database that tracks the purchases of employees. Here are some details: 3 employees buy auto parts, tools and office supplies for a maintenance shop. I would like to track the employee, purchase details, vendor used and catagorize the purchase as either tools, auto parts, tires or office supplies. Then quarterly our RA will run a query to print a report that show how much has been spent on the different catagories. I know I will need tables for: employees, catagories, purchase details and invoices. Does this seem correct? Does anyone have any suggestions for a better design? Will I need a junction table? Thanks. -- Ron A. |
#4
|
|||
|
|||
New Database Design
Thanks Steve,
Here is a follow up question. The purchase number used is the registration number for the vehicle, so since that would create duplicate purchase numbers, would I be correct in using an auto number for the PurchaseID and add a column for a purchaseNumber? Also, should this be done with the TbleInvoice? Thanks again. -- Ron A. "Steve" wrote: Hi Ron, Consider the following tables or a variation thereof ........... TblEmployee EmployeeID EmpFName EmpLName TblPurchaseCategory PurchaseCategoryID PurchaseCategory TblVendor VendorID Vendor TblPurchase PurchaseID EmployeeID VendorID PurchaseDate TblPurchaseDetail PurchaseDetailID PurchaseID PurchaseCategoryID Item Quantity Price TblInvoice InvoiceID PurchaseID InvoiceDate DatePaid Steve "Ron A." wrote in message ... I need to create a database that tracks the purchases of employees. Here are some details: 3 employees buy auto parts, tools and office supplies for a maintenance shop. I would like to track the employee, purchase details, vendor used and catagorize the purchase as either tools, auto parts, tires or office supplies. Then quarterly our RA will run a query to print a report that show how much has been spent on the different catagories. I know I will need tables for: employees, catagories, purchase details and invoices. Does this seem correct? Does anyone have any suggestions for a better design? Will I need a junction table? Thanks. -- Ron A. |
#5
|
|||
|
|||
New Database Design
Would I be correct in using an auto number for the PurchaseID and add a
column for a purchaseNumber Yes! I'm a stauch believer in using an autonumber for the primary key of EVERY table. One compelling reason is that Access automatically generates an unique autonomber for every record. If you use anything else for an autonumber, you rely on user input and that opens you up to user error (typos). In TblInvoice, InvoiceID should be autonumber for the same reason. Regarding PurchaseID, it's a foreign key and should be number data type long integer. To enter invoices, you could use a form/subform where the main form is based on TblPurchase and the subform is based on TblInvoice with the linkmaster and linkchild properties set to PurchaseID. This way PurchaseID (the value in the main form) would be automatically entered for PurchaseID in the subform for every new record. Ron, I provide help with Access, Excel and Word applications for a nominal fee. If you need extensive help with your database, I can help you for only a small fee. If you only have small questions like here in your post, post to the newsgroup; if I see them, I'll try and answer. Steve "Ron A." wrote in message ... Thanks Steve, Here is a follow up question. The purchase number used is the registration number for the vehicle, so since that would create duplicate purchase numbers, would I be correct in using an auto number for the PurchaseID and add a column for a purchaseNumber? Also, should this be done with the TbleInvoice? Thanks again. -- Ron A. "Steve" wrote: Hi Ron, Consider the following tables or a variation thereof ........... TblEmployee EmployeeID EmpFName EmpLName TblPurchaseCategory PurchaseCategoryID PurchaseCategory TblVendor VendorID Vendor TblPurchase PurchaseID EmployeeID VendorID PurchaseDate TblPurchaseDetail PurchaseDetailID PurchaseID PurchaseCategoryID Item Quantity Price TblInvoice InvoiceID PurchaseID InvoiceDate DatePaid Steve "Ron A." wrote in message ... I need to create a database that tracks the purchases of employees. Here are some details: 3 employees buy auto parts, tools and office supplies for a maintenance shop. I would like to track the employee, purchase details, vendor used and catagorize the purchase as either tools, auto parts, tires or office supplies. Then quarterly our RA will run a query to print a report that show how much has been spent on the different catagories. I know I will need tables for: employees, catagories, purchase details and invoices. Does this seem correct? Does anyone have any suggestions for a better design? Will I need a junction table? Thanks. -- Ron A. |
#6
|
|||
|
|||
New Database Design - if stevie was any good, he would not have to grovel for work
"Steve" wrote in message
m... Ron, I provide help with Access, Excel and Word applications for a nominal fee. If you need extensive help with your database, I can help you for only a small fee. If you only have small questions like here in your post, post to the newsgroup; if I see them, I'll try and answer. Steve These newsgroups are provided by Microsoft for FREE peer to peer support. There are many highly qualified individuals who gladly help for free. Stevie is not one of them, but he is the only one who just does not get the idea of "FREE" support. He offers questionable results at unreasonable prices. If he was any good, the "thousands" of people he claims to have helped would be flooding him with work, but there appears to be a continuous drought and he needs to constantly grovel for work. A few gems gleaned from the Word New User newsgroup over the Christmas holidays to show Stevie's "expertise" in Word. Dec 17, 2008 7:47 pm Word 2007 .......... In older versions of Word you could highlght some text then go to Format - Change Case and change the case of the hoghloghted text. Is this still available in Word 2007? Where? Thanks! Steve Dec 22, 2008 8:22 pm I am designing a series of paystubs for a client. I start in landscape and draw a table then add columns and rows to setup labels and their corresponding value. This all works fine. After a landscape version is completed, I next need to design a portrait version. Rather than strating from scratch, I'd like to be able to cut and paste from the landscape version and design the portrait version. Steve Dec 24, 2008, 1:12 PM How do you protect the document for filling in forms? Steve One of my favourites: Dec 30, 2008 8:07 PM - a reply to stevie (The original poster asked how to sort a list and stevie offered to create the OP an Access database) Steve wrote: Yes, you are right but a database is the correct tool to use not a spreadsheet. Not at all. If it's just a simple list then a spreadsheet is perfectly adequate... John... Visio MVP |
#7
|
|||
|
|||
New Database Design
Steve's solicitation was inappropriate. If you are even considering using
his "services", do a newsgroup search first. There are things about his track record that you should know. There is much to be said for using autonumber when the number itself doesn't matter, but it is unnecessarily rigid to say you should use autonumber as the PK of every table. There are ways of generating sequential numbers, such as would be used for invoice numbers (auditors tend not to like gaps), that do not rely on user input. It could be that the invoice numbering system has changed in the past, and may again in the future, so you would use an autonumber behind the scenes while generating a unique invoice number too, but it all depends on the situation. Gina posted some links that I expect you will find to be quite useful and informative. "Ron A." wrote in message ... Thanks Steve, Here is a follow up question. The purchase number used is the registration number for the vehicle, so since that would create duplicate purchase numbers, would I be correct in using an auto number for the PurchaseID and add a column for a purchaseNumber? Also, should this be done with the TbleInvoice? Thanks again. -- Ron A. "Steve" wrote: Hi Ron, Consider the following tables or a variation thereof ........... TblEmployee EmployeeID EmpFName EmpLName TblPurchaseCategory PurchaseCategoryID PurchaseCategory TblVendor VendorID Vendor TblPurchase PurchaseID EmployeeID VendorID PurchaseDate TblPurchaseDetail PurchaseDetailID PurchaseID PurchaseCategoryID Item Quantity Price TblInvoice InvoiceID PurchaseID InvoiceDate DatePaid Steve "Ron A." wrote in message ... I need to create a database that tracks the purchases of employees. Here are some details: 3 employees buy auto parts, tools and office supplies for a maintenance shop. I would like to track the employee, purchase details, vendor used and catagorize the purchase as either tools, auto parts, tires or office supplies. Then quarterly our RA will run a query to print a report that show how much has been spent on the different catagories. I know I will need tables for: employees, catagories, purchase details and invoices. Does this seem correct? Does anyone have any suggestions for a better design? Will I need a junction table? Thanks. -- Ron A. |
Thread Tools | |
Display Modes | |
|
|