Oracle covering indexes - equivalent to SQL Server INCLUDE indexes ?
For covering indexes in Oracle, does it have anything similar to SQL Server's INCLUDE indexes ?
These allow you to define the index key on just the columns used for selection, keeping the index key narrow, but add the other columns needed to cover the query into the leaf level of the index.
e.g.
CREATE NONCLUSTERED INDEX NC_EmpDep ON Employee(EmployeeID, DepartmentID) INCLUDE (Lastname)
Is there anything similar in Oracle ? Or do you have to define the index on all the columns to get a covering index in Oracle ?
e.g.
CREATE INDEX NC_EmpDep ON Employee(EmployeeID, DepartmentID, Lastname)
That would cover the query, but the index key is now bigger than it needs to be.