![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
#3
| |||
| |||
|
|
When creating indexes how do you guarantee not reading the base table. It seems like the first case did have to read the base table? |
#4
| |||
| |||
|
|
ROOT:EMIT Operator (VA = 5) |RESTRICT Operator (VA = 4)(0)(0)(0)(0)(11) | | |MERGE JOIN Operator (Join Type: Left Outer Join) (VA = 3) | | Using Worktable2 for internal storage. | | Key Count: 1 | | Key Ordering: ASC | | | | |SORT Operator (VA = 1) | | | Average Row width is 22.000000 | | | Using Worktable1 for internal storage. | | | | | | |SCAN Operator (VA = 0) | | | | FROM TABLE | | | | first | | | | a | | | | Using Clustered Index. | | | | Index : first_pkc_1 | | | | Forward Scan. | | | | Positioning by key. | | | | Keys are: | | | | one_id ASC | | | | two_id ASC | | | | date ASC | | | | Using I/O Size 16 Kbytes for data pages. | | | | With MRU Buffer Replacement Strategy for data pages. | | | | |SCAN Operator (VA = 2) | | | FROM TABLE | | | second | | | b | | | Using Clustered Index. | | | Index : XPKsecone | | | Forward Scan. | | | Positioning at index start. | | | Index contains all needed columns. Base table will not be read. | | | Using I/O Size 16 Kbytes for index leaf pages. | | | With LRU Buffer Replacement Strategy for index leaf pages. |
#5
| |||
| |||
|
|
- but the fact the it refers to the "base table" implies that it is using an NCI or the table is not APL. ASE generally refers to the "base table" as an euphemism for the heap, not the CI. |
|
| | | |SCAN Operator (VA = 2) | | | | FROM TABLE | | | | second | | | | b | | | | Using Clustered Index. | | | | Index : XPKsecone | | | | Forward Scan. | | | | Positioning at index start. | | | | Index contains all needed columns. Base table will not be read. |
![]() |
| Thread Tools | |
| Display Modes | |
| |