Download presentation
Presentation is loading. Please wait.
1
Oracle Working Mechanism Okcan Yasin Saygili
2
Who am i? Okcan Yasin Saygili Free consultant and Instructor
Oracle ACE Oracle RAC SIG Turkey Chair Founding member of TROUG
3
Contact http://friendfeed.com/yasinsaygili
4
Start with blog
6
Best Resources and Practise about Oracle Transaction
7
Agenda Introduction Commit Rollback Savepoint Concurrency Consistency
Deadlocks Conclusion
8
Introduction As DBA said ,database is not purpose,database is a tool , we will see better with real time testting. First of all ,we can see Database mechanism about oracle background.
9
Basic Architecture
10
Commit You can write on the system ,you can write plsql command on the database but Commit is require for Developer. If you look for first looking İf you use on the system.This is end of change.
11
Transaction
12
SQL> UPDATE hr.employees SET salary=salary;
107 rows updated. SQL> SELECT XID, STATUS FROM V$TRANSACTION; XID STATUS ACTIVE SQL> ROLLBACK; Rollback complete. SQL> SELECT XID FROM V$TRANSACTION; no rows selected
13
Rollback .Before you created or made something on the system,you can easily recovery with this command depends on system is relax with this command.
14
SQL> UPDATE hr.employees SET last_name=last_name;
107 rows updated. SQL> SELECT XID, STATUS FROM V$TRANSACTION; XID STATUS ACTIVE
15
Savepoint Sometimes you coded on the system ,you need mark somewhere ,you can use this command. If you use back system ,you can use “rollback to “ command.
17
Concurrency If you see one side
This is several users access the data at same time.This is basic definition for concurrency.Certainly this system protect with locking method.Such as When two user access to any data,System imply locking method for ranking.
18
Lock Types DML locks (data locks) DDL locks (dictionary locks)
Oracle Internal Locks/Latches Oracle Distributed Locks Oracle Parallell Cache Management Locks (references:
19
Simple Touch Redo = Every Oracle database has a set of (two or more) redo log files. The redo log records all changes made to data, including both uncommitted and committed changes. In addition to the online redo logs Oracle also stores archive redo logs. All redo logs are used in recovery situations. Rollback = More specifically rollback segments. Rollback segments store the data as it was before changes were made. This is in contrast to the redo log which is a record of the insert/update/deletes. Undo = Rollback segments. They both are really one in the same. Undo data is stored in the undo tablespace. Undo is helpful in building a read consistent view of data. (references:
21
Consistency simple touch 2
Data consistency ,if you change some thing on data , changes something by specific users and other users.
22
Deadlock Two or more user will wait for data locked such as two or more transaction will may deadlock.
23
Deadlock
24
Conclusion Oracle is not complicate structrue .However ,you must learn base of architecture.When you learned structure,it will be better for user.
25
References http://www.ceturk.com/images/cncpt025-410x300.gif
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.