Results 1 to 4 of 4
  1. #1
    Join Date
    Jul 2009

    functional dependency question between phonenum and address

    In a lot of web applications, like a storefront, the user's name, email, address and phone are typically persisted. A firs draft of an accounts relation would therefore have (these are attribute not SQL types)

    {userid, email, name, address, phone}

    {userid} and {email} are obvisous candidate keys, and address seems functionally dependent on phone, so {phone} -> {address}. I'm assuming we persist just one phone number.

    So to get accounts into BCNF (and 5NF), I would decompose it into 'accounts' and 'address_info', where accounts is {userid, email, name, phone} and address_info is {phone, address}.

    But is address really functionally dependenct on phone number in the 'real world' of both cell phones and landlines? A storefront application would probably have a billing address and multiple shipping address. But I'm ignoring that for now.

    A storefront isn't a phone company. It doesn't care if a phone is shared by users living at the same address. It doesn't care, if the phone is shared, whether it is a shared cell (however unlikely that might be) or a shared landline. The application simply wants to avoid an update anomaly when a member's address changes.

    So I'm sort of confused as to whether the FD {phone} -> {address} is really worth worrying about. It seems like it is.


  2. #2
    Join Date
    Feb 2004
    In front of the computer
    Emphatically no, there is no real-world functional dependancy of phone -> address. Mobile phones break that paradigm, and mobile professionals break it spectacularly.

    I have several dozen phone numbers, most of which are virtual (no physical location at all). I have four mailing addresses in the United States, and several more abroad. I use many of those phone numbers with multiple physical addresses, and I use many of them with a single address.

    I might be a rarity today, but I'd be willing to bet heavily that the trend will move more and more toward virtualization.

    In theory, theory and practice are identical. In practice, theory and practice are unrelated.

  3. #3
    Join Date
    Jul 2009
    PatP, thanks for the prompt reply. I appreciate it!

  4. #4
    Join Date
    Jul 2009
    I guess, when thinking of functional dependencies, it really depends (excuse the pun) on who the application is for. If your Verizon, you would need to know where a landline is located. But if you Amazon you probably don't need to worry the relationship between phone number and address.

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