scott@[local]:5432:scottdb]
SQL> select * from dept;
deptno | dname | loc
--------+------------+----------
10 | ACCOUNTING | NEW YORK
20 | RESEARCH | DALLAS
30 | SALES | CHICAGO
40 | OPERATIONS | BOSTON
(4 rows)
scott@[local]:5432:scottdb]
SQL> select * from DEPT; -- DEPT 가 대문자지만 소문자화 합니다.
deptno | dname | loc
--------+------------+----------
10 | ACCOUNTING | NEW YORK
20 | RESEARCH | DALLAS
30 | SALES | CHICAGO
40 | OPERATIONS | BOSTON
(4 rows)
scott@[local]:5432:scottdb]
--------+------------+----------
10 | ACCOUNTING | NEW YORK
scott@[local]:5432:scottdb]
SQL> select * from "Dept"; -- double quote 를 쓸때는 대소문자를 구분합니다.
ERROR: relation "Dept" does not exist
LINE 1: select * from "Dept";
^
scott@[local]:5432:scottdb]
SQL> select * from "DEPT";
ERROR: relation "DEPT" does not exist
LINE 1: select * from "DEPT";
^
scott@[local]:5432:scottdb]
SQL> select * from "dept"; -- 소문자화 했더니 이때는 에러가 안나네요!!
deptno | dname | loc
--------+------------+----------
10 | ACCOUNTING | NEW YORK
20 | RESEARCH | DALLAS
30 | SALES | CHICAGO
40 | OPERATIONS | BOSTON
(4 rows)
scott@[local]:5432:scottdb]
SQL>
내친김에 double quote 에 대해 알아봅시다.