Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    Senior Coder nikos101's Avatar
    Join Date
    Dec 2006
    Location
    London
    Posts
    1,007
    Thanks
    59
    Thanked 10 Times in 10 Posts

    Question same db table for different deal types

    Hi friends


    If you have 15 different foreign exchange options trade types but they share 80% of the same fields would you use the same db table, and just allow null in non shared fields?


  • #2
    Super Moderator guelphdad's Avatar
    Join Date
    Mar 2006
    Location
    St. Catharines, Ontario Canada
    Posts
    2,634
    Thanks
    4
    Thanked 148 Times in 139 Posts
    Not enough information to really say. The important concept is normalizing your data.

  • #3
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,602
    Thanks
    78
    Thanked 4,387 Times in 4,352 Posts
    Big question might be "how many non-shared fields?" and what are their purposes.

    And maybe there's a way to share fields (in a related table) that isn't obvious from lack of information.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • #4
    Senior Coder nikos101's Avatar
    Join Date
    Dec 2006
    Location
    London
    Posts
    1,007
    Thanks
    59
    Thanked 10 Times in 10 Posts
    most banks allow to export data of trades in one big excel sheet even though many fields are blank as shared trades, only thing now is my trades table is so complex that the table is getting real hard to under stand.

    I wish I build it with different tables, but I wanted to save time



  •  

    Posting Permissions

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