Added index for speeding up query last visited SPs