mysql如何創(chuàng)建索引 怎樣用SQL語句為表創(chuàng)建主鍵并自動創(chuàng)建索引?
怎樣用SQL語句為表創(chuàng)建主鍵并自動創(chuàng)建索引?create table(id int identity(1,1)not null primary key,other Column varchar(50)
怎樣用SQL語句為表創(chuàng)建主鍵并自動創(chuàng)建索引?
create table(id int identity(1,1)not null primary key,other Column varchar(50))--將主鍵設(shè)置為表時,數(shù)據(jù)庫將自動創(chuàng)建一個以主鍵為名稱的唯一索引。