Information générale
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Load whole table into Memory
Versions des environnements
hi all
How do i load a whole table into memory as fast as possible ? table size is 130MB
What i want to do
set exclu on
set ansi on
use bhav_data alias bhav
set order to tag syu && unique index on symbol
scan
select open from bhav_data where symbol = bhav.symbol order by date ;
into array aopen
*** process the array
endscan
This runs very slow the first time.
if i do
set exclu on
set ansi on
use bhav_data in 0
select bhav_data
scan
endscan
use bhav_data alias bhav in 0
select bhav
set order to tag syu && unique index on symbol
scan
select open from bhav_data where symbol = bhav.symbol order by date ;
into array aopen
*** process the array
endscan
Runs fast . because it loads the table into memory ????
there is a index on symbol - syu
tia
suhashegde
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement