8. OpenSQL Statements : CREATE VIEW : Example: Create View
 
Share this page                  
Example: Create View
Define a view of employee data including names, salaries, and name of manager.
create view empdpt (ename, sal, dname) 
  as select employee.name, employee.salary, dept.name
  from employee, dept
  where employee.mgr = dept.mgr;