Click here to Skip to main content
15,886,199 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Example: SELECT * FROM TABLE , If I use indexing to fetch data,, since there is no where clause here, indexing has no signification, because there is no where cluase, table scan will occur inspite of indexing right?
Posted

"table scan" applies to index usage, when your selecting all rows from a table the query processor will just read and output from the pages until the end of pages or a row limit (if you have defined one) is reached.
 
Share this answer
 
Comments
Maciej Los 20-Aug-15 17:32pm    
Short and to the point! +5!
Mehdi Gholam 21-Aug-15 1:36am    
Thanks Maciej!
In short: here is very interesting article: Index Scans and Table Scans[^] which explains when table scan and index scan is occurring.
 
Share this answer
 
Comments
Mehdi Gholam 21-Aug-15 1:36am    
5'ed
Maciej Los 23-Aug-15 15:35pm    
Thank you, Mehdi.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900