Skip to content

LATERAL queries #31

@Salva5297

Description

@Salva5297

LATERAL SPARQL queries can be done with SPARQL Anything in Java, but these types of queries cannot be executed properly using pysparql-anything.

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX fx:   <http://sparql.xyz/facade-x/ns/>
PREFIX xyz:  <http://sparql.xyz/facade-x/data/>

SELECT ?entity ?series
WHERE {
    SERVICE <x-sparql-anything:https://sparql-anything.cc/example1.json> {
        ?tvSeries xyz:name ?seriesName .
        ?tvSeries xyz:stars ?star .
        ?star fx:anySlot "Courteney Cox" .
    }
    
    BIND (STRLANG(?seriesName,"en") AS ?series)
    
    LATERAL {
        SERVICE <https://query.wikidata.org/sparql> {
          ?entity rdfs:label ?series
        }
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions