Subject | index desc |
---|---|
Author | bill_lam |
Post date | 2006-08-02T14:31:58Z |
Suppose I am going to select in both ascending and desending order.
select * from foo order by a
select * from foo order by a desc
Is only one index for ascending order (default) sufficient, or I have to use 2
index, one ascend and the other desc?
create index foo_a on foo(a)
create desc index foo_a_d on foo(a)
Also is it possible to create a composite index on some ascending column and
some descending column, like equivalent of
create index foo_inx on foo(a , b desc, c)
--
regards,
bill
select * from foo order by a
select * from foo order by a desc
Is only one index for ascending order (default) sufficient, or I have to use 2
index, one ascend and the other desc?
create index foo_a on foo(a)
create desc index foo_a_d on foo(a)
Also is it possible to create a composite index on some ascending column and
some descending column, like equivalent of
create index foo_inx on foo(a , b desc, c)
--
regards,
bill