views:

254

answers:

4

A table in my area of responsibility of our product has been criticised as having more than one orthogonal index.

What is an orthogonal index?
Why is it bad?
How can the situation be avoided?

--Update--
The back-end database engine isn't necessarily relevant here as our application is database-agnostic. But if it helps, Oracle is one possibility.

The table in question isn't used for financial analysis.

A: 

Othogonal simply means independent i.e. unrelated to the main concern.

John Topley
A: 

I believe I have heard the term 'orthogonal index' in two separate occasions, but I have no further knowledge if that is an acknowledged term. In both occasions, they were referring to an index that wasn't to be used by the query optimiser, since:

  • in one occasion, it indexed a completely irrelevant column, never used as search criteria or sorting column; the term sounded "outlandish" to me, but I didn't object :)

  • in the other occasion, it was a two column index, but the order of the columns in the field was the reverse than the one needed.

I have absolutely no idea if this is relevant to your question :)

ΤΖΩΤΖΙΟΥ
+2  A: 

Orthogonal means independent of each other.

No idea why it would be bad. In fact, i usually use secondary indexes (besides the 'id' autoincrement primary key) when there's a common query that has nothing to do with the primary one.

Javier
A: 

I might be answering my own question here, but feel free to jump in with your own thoughts.

Javier's answer (+1) led me on to think that maybe the point here is that having more than one unique index could be a bad thing if the items in that index are completely unrelated.

In other words, you're increasing the chances of real data being impossible to store because of a secondary indexes uniqueness constraints. It would also potentially introduce artificial constraints on the data that shouldn't necessarily be there.

ColinYounger