Jump to content

Archived

This topic is now archived and is closed to further replies.

coolex

What does "KEY `sourceID` (`sourceID`)" mean?

Recommended Posts

Hello!

I saw this MySQL Code in a PHP Script:

CREATE TABLE `transaction` (
  `ID` int(11) NOT NULL auto_increment,
  `sourceID` int(11) NOT NULL default '0',
  'comment' varchar(200),
  PRIMARY KEY  (`UID`),
  KEY `sourceID` (`sourceID`)
)

I know what a Foreign Key is.
But what does "KEY `sourceID` (`sourceID`)" mean? Is it something like a Foreign key?
Hope you can help me.
Thank you.

Share this post


Link to post
Share on other sites
KEY is just a synonym for INDEX.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.