Solved

Sql Server Database Design ,ER and Normalization

Posted on 2011-02-25
12
397 Views
Last Modified: 2012-05-11
Hi Everyone,

I have a task to design a database (sql server) , i have 65 fields identified.

some one give me a lead,how to approach and what are all the stuff i have to take care.

Thanks in Advance !
0
Comment
Question by:Sha1395
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 6
12 Comments
 
LVL 53

Expert Comment

by:Dhaest
ID: 34978360
Start with:
Create separate tables for each group of related data and identify each row with a unique column or set of columns (the primary key).


Database Normalization Basics
http://databases.about.com/od/specificproducts/a/normalization.htm
0
 

Author Comment

by:Sha1395
ID: 34978379
Hey Dhaest,

Nice to get an answer from you promptly,am glad you are expertise in Sql Server also.

I have a question

1) how can i identified which field goes to which group (ofcourse , Employee details goes to employee table) but similar kinda field what i suppose to do ?
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 34978395
That's very hard to tell without really knowing what kind of system you are developing, what fields you want to update. I usually try to determine to see which fields are logically grouped, so that the crud-screens (update/delete/insert are mostly for 1 table)
0
PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

 

Author Comment

by:Sha1395
ID: 34978568
is this anyway i can send the mapping fields,privately ?
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 34978615
Why not post them here ? It are just names of columns ... (no private data)
0
 

Author Comment

by:Sha1395
ID: 34978643
you are right,i was keep on thinking am posting the data also.

here you go...attached xls file.

basically i wanna create a ER diagram, then i will go and create a table (table is identified also) but i have to do normalization.

Based on your answer i will start walking on your path
To-DHAEST.xls
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 34978672
Perhaps you can create another table witht the regional attributes, like city code, city name, state, postcode, country.

You can link this table in your home address fields and in your job data fields
0
 

Author Comment

by:Sha1395
ID: 34978709
very valid point,so basically i will create another table (regional table) (fields : city cod,name,state,count and Zip)

Map with Home and Job tables.

Great !

what's the logic to create an ER diagram. bcoz already you know i got the tables and fileds and i have to add this new table also.
0
 
LVL 53

Accepted Solution

by:
Dhaest earned 500 total points
ID: 34978729
To create an ERD, there are several possibilities. You can use design-programs (like visio) or sometimes you can do this in your database directly

Example access: http://databases.about.com/cs/specificproducts/g/er.htm
0
 

Author Comment

by:Sha1395
ID: 34993360
Hi Dhaest,

based on your suggestion Created ER diagram,please advice how can i improve my ER diagram
ER-Diagram.pdf
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 34994843
Some small remarks:
1. Why use the countryCode in your job_tbl ? I think that the job is linked to a location (location_tbl), so you can retrieve the country though that way

2. The communication table can be easier (smaller in space), by fe using a spearate table communicationType (commTypeId, commType) whare you store fe (1, 'phone private' - 2, 'phone public' - 3, 'cellphone' - 4, 'email public', ...) In your communication_tbl, you just need (commCode, commType, value (where you really store the emailaddress, phonenumber, ....)

3. Another remark about communications: in your ERD, the person can only have 1 communicatinoCode, so remove the communicationCode from your person_tbl and store the personID in the communication_tbl. If you do so, you can store more communucations for your person.
If you think further than that, you can even add a column CompanyID in the communicaton_tbl, so that you can also add email, phone's of company's in that table
(and evern furhter thinking: just add one id to the table, fe linkedid, which can refer to the table person or company)

0
 

Author Comment

by:Sha1395
ID: 34995757
1. Why use the countryCode in your job_tbl ? I think that the job is linked to a location (location_tbl), so you can retrieve the country though that way.

True,the reason i used country code to retrieve the Currency not for location.is that make sense ?


I will modify the Communication Table based on your suggestion.Apart from that is this anything else i have to change ?

Thank you so much for your suggestion
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
asp web application 3 56
How to force output to ascii 2 64
Set custom font WPF 2 27
How to send the email using C# with embedded HTML TABLE 3 25
This article describes a simple method to resize a control at runtime.  It includes ready-to-use source code and a complete sample demonstration application.  We'll also talk about C# Extension Methods. Introduction In one of my applications…
We all know that functional code is the leg that any good program stands on when it comes right down to it, however, if your program lacks a good user interface your product may not have the appeal needed to keep your customers happy. This issue can…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

752 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