optimize import quries to stop the madness.