Results 1 to 3 of 3
  1. #1
    Join Date
    Dec 2013

    Meaning PF in many to many relationship.

    I am making a entity diagramm with "dezign for databases".
    I am making a many to many relationship between two tables:

    PK CompID

    PK CertificateId

    When i make the link between the tables a new table appears (as expected).

    PF CertificateId
    PF CompId

    I am wondering what the PF means?
    I have googled PF but do not seem to find an answer.

  2. #2
    Join Date
    Jan 2007
    See here
    Foreign Keys

    The Foreign Key (FK) in an entity is the reference to the primary key of another entity. In the ERD that attribute will be indicated with 'FK' behind its name. The foreign key of an entity can also be part of the primary key, in that case the attribute will be indicated with 'PF' behind its name. This is usually the case with the link-entities, because you usually link two instances only once together (with 1 sale only 1 product type is sold 1 time).
    Home | Blog

  3. #3
    Join Date
    Nov 2004
    out on a limb
    another shorthand is
    PK: Primary Key
    FK: Foreign Key
    PFK: is both a Primary and a Foreign Key
    often where PFK is denoted the primary key is a composite of two or more foreign keys
    table students contains details of students has a PK of Student registration id

    table subjects contains details of subjects a offered, has a pk of subject id

    to know what subjects a student is enrolled on you need to associate students with subjects. using a composite primary key comprising student id and subject id you get a design that only allows a many to many relationship where a student can enroll on may subjects and one subject can have many students enrolled. have a look at intersection / junction tables

    you could use another primary key, but there becomes a risk that without further design you may get more than one enrolment pairing (ie more than one definition of student and subject which you don't want)
    I'd rather be riding on the Tiger 800 or the Norton

Posting Permissions

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