Enhance block query to handle extended entities