SQL/PL SQL Oracle By Rana Umer
Performance Tuning Indexes ROWID View Sequences Oracle By Rana Umer
Performance Tuning Oracle By Rana Umer Indexing a table is an access strategy, that is a way to sort and search records in the table. Indexes are essential to improve the speed with which records can be located and retrieved from a table. An index is an ordered list of the contents of column or columns of a table. When index is created, it is assigned a ROWID for each row before it sorts.( Data Value in the index ) Records in the index are sorted in the ascending order of the index column.
Performance Tuning Oracle By Rana Umer Create Index On ( ) Select ROWID, Column-Name from Tabke-Name; Create Unique Index On ( ) Create Index On ( Reverse Alter INDEX ReBuild NOREVERSE; Drop index Alter Table index
Performance Tuning Oracle By Rana Umer ROWID Take Space in Table Data Dictionary In Bytes AAAHeeAABAAAMWCAAA Data Object Number AAAHee Datafile Number AAB Data Block AAAMWC Row Number AAA
View Oracle By Rana Umer Use the CREATE VIEW statement to define a view, which is a logical table based on one or more tables or views. A view contains no data itself. The tables upon which a view is based are called base tables. Create VIEW AS Select * from Table; Insert into VIEW Values (Values, Values …) Delete From ViewName where Name =Ali; Update ViewName Set column=values Where condition
Sequences Oracle By Rana Umer The Oracle SEQUENCE function allows you to create auto-numbering fields by using sequences. An Oracle sequence is an object that is used to generate incrementing or decrementing numbers. CREATE SEQUENCE MINVALUE value MAXVALUE value START WITH value INCREMENT BY value CACHE value;
Sequences Oracle By Rana Umer CREATE SEQUENCE user_seq MINVALUE 1 MAXVALUE START WITH 1 INCREMENT BY 1 CACHE 100; Drop Sequence Alter Sequence Maxvalue=50000; Insert into TableName Valuse ( user_seq, Ali,MCS,Evening);