-
It take long time in Query this statement
Hi,
I have run this command:
Select /*+ choose */ distinct decode
(a.adfl,'D',a.stod )stod,decode(a.adfl,'D',to_char
(cvt_date(a.stod),'dd/mm/rrrr hh24:mi')) arr_date
From aftbkk a
Where a.stod > ' '
And a.adfl = 'D'
Order by 1 desc
It take about 3 minutes. The rows return from quiried table is about 69711 rows. I have a two-column index on column "adfl" and "stod"
Before run the statement above, I have analyze estimate table 'aftbkk' and here the result:
0 SELECT STATEMENT Cost=1909
Optimizer=HINT: CHOOSE
1 0 SORT (ORDER BY)
2 1 SORT (UNIQUE)
3 2 INDEX (RANGE SCAN)
OF 'AFTBKK_ADFL_STOD_IDX'
What should I do, please help
Pat
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|