Mysql Indexes and Primary vs Unique
Posted on 2008-11-02
I have been working on simple database stuff.
Took the suggestions from here...
But wondering a little bit more about why.
*Indexes and Primary vs Unique*
From my reading, I have set up my table to have "userName" be Unique...
Because I don't want two values to be the same.
Not really sure why I have my "memberID" set up for Primary...and not Unique...
Now, both are indexs.
Why would I want that? Or is that just a default of what happens when I make something a Primary / Unique.
I am just guessing that it makes the data look different than the other columns when doing querys.
Thanks for the help