Skip to content

Instantly share code, notes, and snippets.

@loclamor
Created July 24, 2013 14:29
Show Gist options
  • Save loclamor/6071070 to your computer and use it in GitHub Desktop.
Save loclamor/6071070 to your computer and use it in GitHub Desktop.
select p.idprel,
e.lespcm,
s.idstation
from opt_prelevement p
INNER JOIN espece e ON (p.cesp = e.cesp)
INNER JOIN opt_station s ON (p.idstation = s.idstation)
order by idprel limit 10 offset 289900
=> 49.394ms
---------------------------------------------------------
select p.idprel,
e.lespcm,
s.idstation
from opt_prelevement p
INNER JOIN espece e ON (p.cesp = e.cesp)
INNER JOIN opt_station s ON (p.idstation = s.idstation)
where p.idprel > 'E543384678' //c'est l'ID du 289899 eme prelevement
order by idprel limit 10
=> 30ms
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment