SQL Views
SQL Views
결과를 기반으로 하는 가상 테이블
SQL CREATE VIEW Statement
CREATE VIEW view_name AS
SELECT column1, column2, ...
FROM table_name
WHERE condition;
SQL CREATE VIEW Examples
CREATE VIEW [Brazil Customers] AS
SELECT CustomerName, ContactName
FROM Customers
WHERE Country='Brazil';
SQL Updating a View
CREATE OR REPLACE VIEW view_name AS
SELECT column1, column2, ...
FROM table_name
WHERE condition;
SQL Dropping a View
DROP VIEW view_name;
'Computer Science > Database' 카테고리의 다른 글
W3Schools SQL | #54 SQL INJECTION 악성 기술 (0) | 2022.10.30 |
---|---|
W3Schools SQL | #52 SQL WORKING WITH DATES 날짜 이용법 (0) | 2022.10.30 |
W3Schools SQL | #51 SQL AUTO INCREMENT 필드 (0) | 2022.10.30 |
W3Schools SQL | #50 SQL CREATE INDEX 구문 (0) | 2022.10.30 |
W3Schools SQL | #49 SQL DEFAULT CONSTRAINT 이용법 (0) | 2022.10.30 |