eRQL Documentation

The query language eRQL we generated is based on the RDF Query Language (RQL). The goal was to construct the language as easy as possible to be used also for users not familiar with RDF. That's why we named the language easy RQL (eRQL).

The main design goals for eRQL had been:

Properties of eRQL

Query Modi of eRQL

Statement-Modus

Is active by enclosing the query into brackets "[...]". In this modus only the statements fitting the query will be returned. There will be no additional statements form the neighbourhood included. In the following graph the result for the query "[Picasso]" for the museum example is shown.

Point Of Interest-Modus (POI)

Is default but can be explicitly activated by enclosing the query into braces "{...}". It enforces to include the statements of the neighbourhood with a distance of one. In case the included neighbourhood should be extended the braces can be used cumulative, e.g. {{Picasso}} includes all statements containing 'Picasso' plus their neighbourhood with a distance of two. It is the default modus which means the queries "Picasso" and "{Picasso}" are equal. Alternatively, for a more easy way to write the symbol "~" can be used, e.g. "~Picasso". Please note that the default setting for POI in this case is still valid, which means that "~Picasso" is equal to "~{Picasso}" which is equal to "{{Picasso}}". The "~" can also be used cumulative. In that sense "~~~Picasso" is equal to "~~~{Picasso}" which is equal to "{{{{Picasso}}}}" and will return the found statements with a neighbourhood of a distance of four. See below the result for the query "Picasso" (equal to the query "{Picasso}"). The additional statements compared to the statement-modus are highlighted.

Document-Modus

Is active by enclosing the query into a left angle bracket and a right angle bracket "<...>". For each statement fitting the query all statements having the same source document will be included.

eRQL Syntax (BNF)

       <Query> ::=  <Disjunction>

<Disjunction> ::=  <Conjunction> | <Disjunction> OR <Conjunction>
<Conjunction> ::=  <SubQuery> |
                    <Conjunction> AND <SubQuery> |
                    <Conjunction> <SubQuery>

<SubQuery> ::=  <Literal> |
                    { <Disjunction> } | ~ <Disjunction> | { <Literal> } |
                    < <Disjunction> > | < <Literal> > | [ <Disjunction> ] |
                    [ <Literal> ] | ( <Disjunction> )

<Literal> ::=   " <STRING_LITERAL> " |
                    <STRING_LITERAL> |
                    <URI_LITERAL>