Labels

2017 absence absence management Account accounting AIM aliases AME and API application application utilities lookups approval assignments ATO Australia Bank bi publisher budget business business groups CAGR candidates cartisian product case CEMLI Center Stage channels Classification competency concurrent Configuration configuration profile constants contextualization conversion correction cost costing coverage area customization data database date DateTracked deductions define design develop DFF diagnostics document earnings ebs EIT Element employee enhancements erp excel expression extension failure Fastformula FBT Flexfield FND fndload foreign key forms Formula fringe benefit FRM-40654 from FTE Functions fund fusion GL global transfer grade help hierarchy HR HRMS human resource management system implementation income information interfaces internet interview job join key flexfield KFF KPI language learning leave legal employer legislation links lists localization location management New Year obia obiee OLF onboarding oracle oracle applications oracle descriptive flex field oracle descriptive flexfield oracle ebs oracle erp oracle fusion HCM oracle hrms oracle hrms interview questions oracle hrms modules oracle hrms modules list oracle hrms organization oracle hrms table oracle hrms tables oracle hrms tutorial oracle irecruitment oracle legal entities oracle lookups oracle organization hierarchy oracle payroll oracle payroll interview questions oracle payroll tables oracle self service order by Organization organization type otbi package package body package specification patch payg Payment payroll people group perform person personalisation phase pl/sql position primary key process profile programs project qualifier Query question questions Recruiting Center Recruitment regex regular expression reporting tool reports requests requirement requisition resume retropay RICE salary schema security profile select SIT smartorg sql statutory stores STP Super Superannuation system systems Table Taleo taleo 15B Taleo Recruitment tax termination test testing trunc update user group user management user type value set variables View Views Web ADI webadi where work relationship

Tuesday, 10 November 2015

Oracle SQL Statement Types and Usage - Part III

Data Control Language (DCL) 
The Data Control Language (DCL) is a subset of the Structured Query Lanaguge (SQL) that allows database administrators to configure security access to relational databases.Two types of DCL commands are GRANT and REVOKE. Only Database Administrator’s or owner’s of the database object can provide/remove privileges on a database object.

GRANT:
Gives user’s access privileges to database.


Syntax:
GRANT privilege_name
ON object_name
TO {user_name |PUBLIC |role_name}
[WITH GRANT OPTION];

Examples:
grant select on
emp to scott;
grant select,insert,delete on
emp to scott;

REVOKE:
Withdraw access privileges given with the GRANT command.

Syntax:
REVOKE privilege_name
ON object_name
FROM {user_name |PUBLIC |role_name} ;

Example:
revoke insert, delete on
emp from scott;

========================



Transaction Control Language (TCL) :
TCL statements used to manage the changes made by DML statements. It allows statements to be grouped together into logical transactions.

COMMIT:
Permanent save to work done.here we can’t roll back once applied commit.

Example:
COMMIT;

SAVEPOINT:
identify a point in a transaction and which you can later roll back also.

Example:
save point to sp1;
roll back to sp1;

ROLLBACK:
Restore database to original since the last COMMIT

Example:

ROLLBACK;

No comments:

Post a Comment