MySQL必知必會——第4章 檢索數據

1 檢索單列 查看一個表中包含哪些列名 檢索單個列:select 列名 from 表名 2 檢索多列 命令:select 列名1,列名2 from 表名 3 檢索所有列 命令:select * from 表名 4 檢索列的所有不同取值 只返回指令列中不重複的值:select distinct 列名 from 表名 不加distinct 加distinct (注意:distinct必須放在列名前面)
相關文章
相關標籤/搜索