import: avoid intermingled use of sqlite stmt within dt_image_import()