Results 1 to 4 of 4

Thread: about normalization

  1. #1
    Join Date
    Nov 2007
    Posts
    1

    about normalization

    hi ,

    i m new here, and doing some project in mysql , can any one help me out, its about the normalizing the tables, in what kind of circumstances we do not need to normalize the tables pls guys help me out

    pls reply me asap

    thnx

  2. #2
    Join Date
    Feb 2008
    Posts
    2

    Smile Normalisation

    The Process of Normalisation is used to remove duplicate data from Database Tables. For example: Where you may have a value stored multiple times, you would need to (by using Normalisation), remove the need for duplicate Data. The best way to do this is by using a tool called an Entity Relationship Diagram. An Entity may be a physical object (such as a Customer), or a Concept (such as Payments). Using the ERD you can establish which items are likely to be duplicated, and which are to remain as single entities. The relationships between them may be, A Customer makes one or many payments. The entities form the basis of the Table, the Attributes form the other distinct data in your Database. Say the Entity was a Customer (this would become the Table), the Attributes for the Customer would be, Customer ID (in this case the Primary Key), other Attributes would be details such as Title, Forename, Surname, and any other information you wish to store about the Customer. Where you have many items they would be seperated out into another table, and a Foreign Key would be used to link the Primary Key of the one table (Customers) to the Foreign Key in the Payments Table (Customer ID).

    I hope this makes sense to you?

    Many thanks,

    Tech

  3. #3
    Join Date
    Feb 2008
    Posts
    1
    What if there were cause for many to many relationship? For example, if you had a list of products and keywords. A product could have more than one keyword and vice versa. How would you normalize that situation?

    For example if we were describing fruit.

    Fruit
    ---------
    Apples
    Grapes
    Oranges
    Lemon
    Pears
    Bananas
    Lime

    Keywords
    ---------
    Round
    Citrus
    Green
    Red
    Yellow
    Orange
    Tart
    Sweet

    You can see how a lemon could use both citrus and yellow. On the same token the keyword citrus could also be applied to lime and orange. Either way it goes, you'll still have redundant data wouldnt you? Even if you set up a junction table wouldn't it be redundant data?

  4. #4
    Join Date
    Feb 2008
    Posts
    2

    Normalisation

    There are many tools used to normalise data, but theoretically, you the many to many tables need putting into a seperate table. Also, in this situation, the Entities would be the fruit, and attributes of this entity could be type and colour. It also depends on the type of data you will storing. Remember, only store data that you will be using for some reason. For example: it would be necessary to put items such as colour, and type in the example given above under the entity of fruit, but unless you are using this data (say for example: either providing factual information about fruits, or for say a supermarkey application), there are many items that would not necessarily be required. I assume as you are using the word keyword in this situation you are referring to some kind of search engine, in which case, the type of fruit (lemon) could have a colour attribute (ie yellow) in the fruit table, it could also have a type (ie citrus), it could also have a shape attribute, in which you may store oval as the shape. The ERD is used as a tool to assist in the development of a Database from scratch, where in many situations, a Customer may already have either a Database or some kind of manual paper based method they use. I had a similar problem when creating a database, you can spend too much time thinking about data that will not necessarily be used for any reason, ie, why store the data to begin with. The hardest thing about either normalisation or ERD is knowing where to stop, ie, only store the information you will use at some point, or where used in a process. This is an entirely different section in itself however. Hope this helps?

Posting Permissions

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