count in SERVICE query doen not include infered triples

Description

I have 2 repositories with subClassOf rule turned on. When I run query on repository A, it returns correct number (include infered statement is checked)
SELECT (count(distinct ?foo) as ?count) WHERE
{
?foo rdf:type re:Supertype.
}

When I run query on repository B which takes results from repository A using SERVICE, it counts only explicit statements.

SELECT * WHERE { SERVICE <http://localhost:8080/openrdf-sesame/repositories/A>
{
SELECT (count(distinct ?foo) as ?count) WHERE
{
?foo rdf:type re:Supertype .
}
}
}

I'm not sure whether it is problem of Sesame or Owlim.

Environment

I use Owlim 5.4, but I changed included Sesame 2.7.3 to Sesame 2.7.4. Sesame Workbench

Status

Assignee

Jeen Broekstra

Reporter

Marek Šurek

Labels

None

Components

Fix versions

Affects versions

Priority

Major
Configure