SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Member
    Join Date
    Aug 2010
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Two column s values must not be replicted. How it is possible???

    Hi,


    I m beginner to the MySQL. I m having 5 feilds in my db, and i have used primary key to avoid the duplicate values in a single field. But what i need is, another field s value also must not replicated. So wat can i do to fix tis problem.. Help anyone!!!!

    Waiting for the reply...

    Thanks in advance

  2. #2
    From Italy with love silver trophybronze trophy
    guido2004's Avatar
    Join Date
    Sep 2004
    Posts
    9,506
    Mentioned
    163 Post(s)
    Tagged
    4 Thread(s)
    They are called columns. Just to avoid confusion

    One thing you can do is create a unique index on that other column.

  3. #3
    SitePoint Guru
    Join Date
    Sep 2008
    Posts
    977
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    if you post your create table statement, we might be able to help further.
    bazz


Bookmarks

Posting Permissions

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