SELECT ?u ?s {
  {
    SELECT ?u ('a' AS ?s) {
      ?u a rdfs:Resource
    }
    ORDER BY ?u
    LIMIT 1
  }
  UNION
  {
    SELECT ?u ?s {
      SERVICE <%s> {
        SELECT ?u ('b' AS ?s) {
          ?u nrl:indexed true
        }
        ORDER BY ?u
        LIMIT 1
      }
      ?u a rdfs:Resource
    }
  }
}
