how to give permission to users that users can
update/insert/delete on a row of table on timeing 10am to
6pm only?
Answer Posted / pariksheet de
Grant Insert,Update,Delete
On Employees
To All
-----------------------------------------------
Create Trigger Upd_Employees
Before Insert,Update,Delete on Employees
For Each Row
Begin
if to_char(sysdate,'Dy') in
('Mon','Tues','Wed','Thrs','Fri','Sat','Sun') and to_char
(sysdate,'hr:mi') not between ('10:00') and ('6:00')
then raise_application_error(-
20145,'Insertion/Updation/Deletion can take place between
10:00 am and 6:00);
end if;
end;
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What are sql functions? Describe the different types of sql functions?
How do I delete a trigger?
Explain the structure of pl/sql in brief.
How many clustered indexes can be created on a table?
What are the main features of cursor?
explain access control lists. : Sql dba
What are the different types of constraints?
What do you mean by rowid?
What is dml statement?
What is package in pl sql with an examples?
What is dynamic sql in pl sql?
What are different methods to trace the pl/sql code?
How you improve the performance of sql*loader? : aql loader
how to increment dates by 1 in mysql? : Sql dba
Can we insert in sql function?