Skip to content

Commit 59aecb9

Browse files
authored
Create 3-create-view-with-annotations.sql
1 parent 07cf30c commit 59aecb9

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
REM Script for 23c: 3-create-view-with-annotations.sql
2+
3+
-- create a view with column annotations for emp_id, emp_name, and emp_dname and an annotation for the view itself
4+
5+
create or replace view empdept_ann
6+
(emp_id annotations (identity, display 'employee Id', category 'emp info'),
7+
emp_name annotations (display 'employee name', category 'emp info'),
8+
emp_dname annotations (category 'emp info')
9+
)
10+
annotations (title 'employee view')
11+
as select e.empno, e.ename, d.dname
12+
from emp e, dept d
13+
where e.deptno=d.deptno and sal>1000;

0 commit comments

Comments
 (0)