Results 1 to 11 of 11
  1. #1
    Join Date
    Apr 2011
    Location
    karachi , Pakistan
    Posts
    13

    E-R Diagram employee system

    Hi,

    i am new in database schema designing. i try to make er diagram of employee system i attach a picture of what i try to make....

    my supervisor give me a task to make database which have employee personal details and that database design should be up to 3NF.

    please check that this is up to 3NF or not.
    Attached Thumbnails Attached Thumbnails sample 1.png  

  2. #2
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    yeah, it's fine, 3nf all the way, baby

    well, except for the fact that the primary keys are not indicated

    so, it's 0nf
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

  3. #3
    Join Date
    Apr 2011
    Location
    karachi , Pakistan
    Posts
    13

    0nf :eek:

    i have only one Primary key that is "emp_id". i have updated this schema design ............so now it is in 3NF?????
    Attached Thumbnails Attached Thumbnails sample 1.png  

  4. #4
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    sorry, now it has tons o' mistakes

    i think you should do some research on what a primary key actually is

    it would not, for instance, contain a column called emp_company_email_UNIQUE
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

  5. #5
    Join Date
    Apr 2011
    Location
    karachi , Pakistan
    Posts
    13

    i got your point

    my supervisor give me a task to make design of database up to 3NF with have some relationship between tables.......

    now i make emp_id as a PK for all tables (does it makes any sense or i should look others feilds as a PK ) excpet two tables
    Attached Thumbnails Attached Thumbnails sample 1-1.png  

  6. #6
    Join Date
    Apr 2011
    Location
    karachi , Pakistan
    Posts
    13

    Plzz check it

    i think now i make it
    Attached Thumbnails Attached Thumbnails sample 1-2.png  

  7. #7
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    the diagram just says PRIMARY for several tables

    a primary key consists of columns, not the word PRIMARY
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

  8. #8
    Join Date
    Apr 2011
    Location
    karachi , Pakistan
    Posts
    13

    i can't get your point!!!!! check this

    TABLE 'Personal info' has a primary key name 'emp_id'
    TABLE 'login_info' has a primary key name 'emp_company_email'
    TABLE 'Bank_info' has a primary key name 'emp_bank_account_no'
    TABLE 'Email' has a primary key name 'emp_email'
    TABLE 'License_info' has a primary key name 'emp_license_no'
    TABLE 'cnic' has a primary key name 'emp_cnic_no'
    TABLE 'Passport' has a primary key name 'emp_passport_no'
    TABLE 'address' has a composite primary key name 'emp_id' & 'emp_address'
    TABLE 'Job' has a composite primary key name 'emp_id' & 'Job_title'
    TABLE 'location' has a composite primary key name 'city' & 'country'
    TABLE 'emergency_contact' has a composite primary key name 'emp_id' & 'person_name'
    Attached Thumbnails Attached Thumbnails sample 1-2.png  

  9. #9
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    yeah, that's great

    i think it's finally ready to be handed in

    let me know what kind of grade you get for this assignment
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

  10. #10
    Join Date
    Apr 2011
    Location
    karachi , Pakistan
    Posts
    13

    Thumbs up Thank You Sir



    it's just the start b/c i give assignment to make erp system of an organization where i currently work........ so their are lot of stuff to discuss thank you again sir

  11. #11
    Join Date
    Apr 2011
    Location
    karachi , Pakistan
    Posts
    13

    Final schema

    This is my complete E-R Diagram of Hr Management System
    Attached Thumbnails Attached Thumbnails sample 1-3.png  

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •