Bonjour,
J'ai un problème avec la requête suivante :
Le résultat est retournée après 30s (4 lignes).
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2 select distinct(year) from selling where type in ('A', 'C') and country like ('%FR%');
Un select * est instantané.
La table contient 1,2 millions de lignes.
J'ai fait un explain mais le résultat me parle pas vraiment:
Si quelqu'un a une piste....
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 Plan hash value: 188663770 ----------------------------------------------------------------------------------- | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time | ----------------------------------------------------------------------------------- | 0 | SELECT STATEMENT | | 5 | 90 | 68344 (1)| 00:13:41 | | 1 | HASH UNIQUE | | 5 | 90 | 68344 (1)| 00:13:41 | |* 2 | TABLE ACCESS FULL| SELLING| 1252 | 22536 | 68343 (1)| 00:13:41 | ----------------------------------------------------------------------------------- Predicate Information (identified by operation id): --------------------------------------------------- 2 - filter("COUNTRY" IS NOT NULL AND "COUNTRY" LIKE '%FR%' AND ("TYPE"='A' OR "TYPE"='C'))
Partager