Fixes bug in query logic
Adds a new ImportDialog and Import process