Llayland’s Food, Oracle, and Haskell

June 14, 2012

Quiz: index including a constant

Filed under: Oracle — llayland @ 3:28 pm

I was surprised when i tried to create an index like this and it actually worked:

Create index t1idx on t1(n1,1);

The question is: Why would you want to do this?

There is at least one valid use case.

About these ads


  1. The index will include entries even when n1 is null.

    Comment by Jeffrey Kemp — June 25, 2012 @ 4:08 am

  2. Spot on. Thanks for answering.

    Restating to take one more shot at a pervasive myth: “where n1 is null” can use the index.

    Comment by llayland — June 27, 2012 @ 2:19 am

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

The Silver is the New Black Theme. Blog at WordPress.com.


Get every new post delivered to your Inbox.

%d bloggers like this: