Cleanup in get_sql_for_supplier_inquiry().