Solved

access primary key

Posted on 2013-01-31
11
172 Views
Last Modified: 2013-02-20
I need some advice I need to create a database Global for my company which have a lot suppliers coming from all over the world. I need to create this database base on each location( sample USA, CANADA, UK, ASIA, AUSTRALIA)... I already have tables from all over the places with manufactures, distributor an extra info..My question is how can I set a primary key for each location supliers so all tables are not auto (01,02,03) and how can I build a relationship and run querys .
How can combine all and not show no repeats because some of the suppliers are repeats in some tables like for example USA and Canada may have some similar supplier.

Thanks for any advice hot to start this Monster!!
0
Comment
Question by:gabgar
  • 3
  • 3
  • 2
  • +3
11 Comments
 
LVL 57
ID: 38841300
You really want an autonumber for the primary key.

 You will also need to create a second unique index on enough data to ensure that you don't enter someone twice.

 Where they are is just another fact (field or "attribute") about the company as is what they are.


  Extra information can be handled in a number of ways. We'd need to walk through that to determine how best to handle.

Jim.
0
 
LVL 57
ID: 38841309
Also, since this sounds like your first DB and your aksing about keys, it's would be worth while to spend an hour on this:

.HOW TO: Introduction to Application & Database Design using Microsoft Access
http://www.youtube.com/watch?v=4YH6gG0Y660

Jim.
0
 
LVL 30

Expert Comment

by:hnasr
ID: 38841379
Autonumber type is used for data that is not localized (i.e not known to the company). For example adding customers you need autonumber as primary key.

For company employees you can use predefined ids.
When using CustomerID in other tables as foreign key, it is a number and can be linked to the Customers table whose PK is autonumber.

You may start with a template from  available templates or Office.com.
Use Northwind database tohelp in designing your required database.
0
 

Author Comment

by:gabgar
ID: 38841389
Jim,

Is there local help from expert exchange?, or can the communication can be via phone?
0
 

Author Comment

by:gabgar
ID: 38841485
Northwind where can I find that?
0
Get up to 2TB FREE CLOUD per backup license!

An exclusive Black Friday offer just for Expert Exchange audience! Buy any of our top-rated backup solutions & get up to 2TB free cloud per system! Perform local & cloud backup in the same step, and restore instantly—anytime, anywhere. Grab this deal now before it disappears!

 

Author Comment

by:gabgar
ID: 38841499
No that one wont work.
0
 
LVL 57

Accepted Solution

by:
Jim Dettman (Microsoft MVP/ EE MVE) earned 500 total points
ID: 38841520
<<Is there local help from expert exchange?, or can the communication can be via phone? >>

 This is it.  Experts-Exchange is a forum based help service and EE itself only provides the means of people to help people.  It doesn't hire Expert's or provide help on it's own.

Jim.
0
 
LVL 30

Expert Comment

by:hnasr
ID: 38841685
From the topics listed, I assumed using Access database.
0
 
LVL 52

Expert Comment

by:Scott Fell, EE MVE
ID: 38841957
"Is there local help from expert exchange?, or can the communication can be via phone?"  
If you are really over your head and want somebody to help you personally, you can look up experts profile and if they have a listed address, you may contact  them probably on a for hire basis.  But first try here as there is really no question too difficult especially with databases and access.  

Instead of trying to do everything at once, take it in bits by asking separate questions.  The first thing to do is set up your tables.  And before doing that, make sure the data is normalized.  http://en.wikipedia.org/wiki/Database_normalization  

This should really be your first question, getting help on your data tables and possibly reformatting or breaking out your database.
0
 
LVL 48

Expert Comment

by:PortletPaul
ID: 38842573
I don't think there is enough information available to advice on your design issues.

e.g. take a well known global supplier like:
IBM

which has smaller entities - such as:
IBM USA
IBM Australia
IBM Europe

Is this one supplier (IBM) or 3? (3 legal entities, different currencies, different taxes etc.)

Will you need a hierarchy of suppliers? e.g. you have both IBM and the many legal entities that belong to IBM.
0
 
LVL 49

Expert Comment

by:Gustav Brock
ID: 38843194
You can either use a GUID as autonumber key (select Autonumber/Replication ID when creating the field); or you can use a compound unique key made from one fixed key unique for each location and one traditional (Long) autonumber.

/gustav
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
'Between' is such a common word we rarely think about it but in SQL it has a very specific definition we should be aware of. While most database vendors will have their own unique phrases to describe it (see references at end) the concept in common …
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now