refactored get_load_type_query