幫資料表命名
就像 PostgreSQL 中所有具名物件一樣,資料表名稱也有一些限制,上一段課程已經說明過。為了避免在建立新資料表時出現問題,你應該能分辨哪些命名方式不被允許。
本練習屬於課程
建立 PostgreSQL 資料庫
練習說明
- 刪除下方含有無效資料表名稱的
CREATE TABLE指令。
動手互動練習
試著完成這個範例程式碼,體驗一下這個練習。
-- Delete me and command below if this table name is invalid
CREATE TABLE 2for1 ();
-- Delete me and command below if this table name is invalid
CREATE TABLE customers ();
-- Delete me and command below if this table name is invalid
CREATE TABLE orders ();
-- Delete me and command below if this table name is invalid
CREATE TABLE service_rendered_by_other_provider ();