What is a VIEW ?
What is a VIEW ?
A view is a named, stored SELECT. It holds no data of its own; every time you query the view, the database runs the underlying query.
CREATE VIEW active_customers AS
SELECT id, name, email
FROM customers
WHERE status = 'active';
SELECT * FROM active_customers WHERE name LIKE 'A%';
GRANT SELECT on the view, not the table).WHERE clause in ten queries.Đăng nhập để tham gia thảo luận cùng mọi người.
Chưa có bình luận nào
Hãy là người đầu tiên chia sẻ suy nghĩ của bạn.