You can use BUILTIN_RESULT.TYPE_BOOLEAN(isinactive) as is_inactive in your query.
BUILTIN_RESULT.TYPE_BOOLEAN(isinactive) as is_inactive