3

To speed up the search for records in a table with an equality predicate on a non key attribute A and selectivity factor fs, is preferable:

  1. A sequential organization on a key attribute ?
  2. A static hash organisation on a key attribute ?
  3. An inverted index on A

I have to justify the answer and give an estimate of query execution cost in all three cases.

To my mind it was

  1. log2⌈Npag(R)⌉ according to this :

cost

  1. ? No info

  2. it depends if it is a clustered or an unclustered index.

Professor answer :

  1. Npag(R) "because indexing is on the key" and "according to the screenshot" (which is provided above, but for me he is wrong on the cell as far as it isn't a memory operation but a equality search)
  2. Npag(R)
  3. Yeah, it depends ...

I don't understand why is he saying the first and where does he take the second. My teacher uses this book he co-writted.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.