Web Ontology Language & SPARQL Query Language (Archived Report)

PDF version of this report
You must have Adobe Acrobat reader to view, save, or print PDF files. The reader
is available for free

Web Ontology Language
& SPARQL Query Language

by Geoff Keston

Docid: 00011563

Publication Date: 1408

Report Type: TUTORIAL


and the Web Ontology Language (OWL) are standards that support the
semantic Web, which proposes to replace unstructured data with
information whose meaning can be processed by software applications.
With the semantic Web now evolving from a concept into a reality, SPARQL and OWL
are slowly expanding beyond the domain of developers to the commercial
world. Stakeholders interested in the practical
applications of these standards may want to begin investigating them as
development on the semantic Web continues to push forward.

Report Contents:

Executive Summary

[return to top
of this report]

The Web Ontology
Language (or OWL, chosen over “WOL” as a more appealing abbreviation)1
and the self-reflexively named SPARQL Protocol and RDF Query Language
(SPARQL) play key roles in the developing semantic Web, which aims to
allow Web files to be machine-processed based on the meaning and type
of their content.

Semantic Web Tutorial
Simple Knowledge
Organization System Tutorial

OWL provides a system for
sorting and labeling information, and it is an alternative to the
Resource Description Framework, or RDF.

SPARQL (pronounced “sparkle”)
is the query language to be used for searching semantic Web content.

The semantic Web has progressed steadily over the past few years, and it has in part moved
from the developmental stage to real world use. Organizations and IT
professionals in sectors that are (or soon will be) affected by the
semantic Web, such as e-commerce and database management, should begin
to study the topic at a strategic level. Organizations in many other
sectors may investigate the semantic Web as resources permit.


[return to top of this report]

To understand the Web
Ontology Language (OWL) and SPARQL Protocol and RDF Query Language
(SPARQL), it is first necessary to understand the semantic Web, for
which they were designed. The semantic Web aims to create the standards
and syntaxes for a type of Web page that would categorize online text
based on the type of content it represents. This differs sharply from
the type of Web page common today. On an ordinary HTML page, words
representing company names, people’s names, titles, and so on cannot
be categorized by an application. From the application’s perspective,
“John Smith & Son” as a company name is in the
same category as “John Smith and his son” as a phrase describing two

The appeal of the
emerging semantic
Web is largely its ability to facilitate better, more customized
searches and to improve content management. In short, it enables Web
information to be managed like data in a database rather than as
unstructured raw text. But delivering these business benefits to users
requires the development and acceptance of some new standards,
including a query language and a way to describe relationships among
data items.

The descriptive
that has been developed for the semantic Web is the Resource
Description Framework (RDF), a W3C standard that covers the labeling
and description of data. OWL is an alternative to RDF that is intended
for use when more flexibility is needed. SPARQL is the semantic Web’s
query language.


working group created OWL 2, which slightly changed and added to
review of the changes in OWL 2, along with other semantic Web
developments, is available in a talk given by the W3C’s Ivan Herman.3

OWL 2 has three
function as “trimmed down” sublanguages that are more efficient for
certain types of tasks:4

  • OWL
    2 EL, for “ontologies
    that contain very large numbers,”
  • OWL 2 QL, for applications
    with “large volumes of instance data,”
  • OWL 2 RL, for “applications
    that require scalable reasoning.”

The sublanguages of
version of OWL — OWL Lite and OWL DL — have not seen extensive use.


SPARQL is the de facto
standard query language for searching RDF documents on the semantic
Web. SPARQL is designed to be a query language specifically for RDF,
including data that is in itself stored in RDF form or data that is
viewed indirectly in RDF form.

As described by IBM, a
SPARQL query representing the English sentence “Find the URL of the
blog by the person named Jon Foobar” would be represented as:

PREFIX foaf:
FROM <bloggers.rdf>
?contributor foaf:name “Jon Foobar” .
?contributor foaf:weblog ?url .

Yahoo! software
architect Dave
Beckett summarizes the structure of SPARQL as follows:6

Prologue (optional) BASE <iri>
  PREFIX prefix:
<iri> (repeatable)
Query Result forms
(required, pick 1)
)sequence of ?variable
  DESCRIBE sequence of
?variable or <iri>
  CONSTRUCT { graph
pattern }
Query Dataset
Add triples to the
background graph (repeatable):
  FROM <iri>
  Add a named graph
Graph Pattern
required for ASK)
WHERE { graph pattern [
FILTER expression ]}
Query Results
Query Results


[return to top of this report]

The fates of OWL and SPARQL are tightly intertwined with the future of the semantic Web. And
that future is still taking shape. Open questions include the following:

  • Will the semantic Web achieve broad adoption? If so, when?
  • If the semantic Web does achieve broad adoption, just how extensively will it be used?
  • What form will the final version of the semantic Web take?
  • Will the current standards used with the semantic Web remain or be replaced?

The semantic Web may take
unexpected turns in its continuing development process, and its
eventual design may replace or minimize the roles of OWL and SPARQL.
Even if the semantic Web does establish a permanent place for itself as
a tool for users at large, it could still be a specialty offering used
for only a limited range of needs. Even optimistic estimates do not
expect the semantic Web to burst into broad use in the next few years,
and some observers are skeptical that the semantic Web will be widely
used even in the future.

But the development of
semantic Web building blocks has now progressed to the point at which
real-world business projects are achievable. With this foundation set,
small numbers of projects that can serve as models to other developers
are emerging, albeit slowly.


[return to top of this report]

Embarking on a semantic
Web project is not an easy or quick task. There are many development
protocols and approaches to understand. Before studying
sub-topics such as SPARQL and OWL, it will be beneficial to first
consider the semantic Web as a whole, starting with business
considerations and moving on to technical considerations. Figure 1
describes a roadmap for an organization to follow as it evaluates how
to approach the semantic Web.

1. Semantic Web Roadmap

Figure 1. Semantic Web Roadmap

(Note that the study of
RDF and OWL may be iterative. OWL is an alternative to RDF that
provides more flexibility. People interested in the semantic Web can
compare the two before moving forward.)

Many organizations will
find that they do not need to seriously address the semantic Web at
this time. But organizations in certain sectors will need to pay close
attention sooner rather than later. In particular, Web developers
should begin to educate themselves on both OWL and SPARQL. Web
developers engaged in advanced e-commerce and data management
technologies will have a stronger impetus to study the semantic Web
than developers focused on HTML-centric sites.

administrators and developers could also benefit from studying SPARQL,
which is a query language like those used in some databases. Oracle has
built support for SPARQL-like queries into its database,
signaling greater use to come throughout the sector.

[return to top of this report]


About the Author

[return to top of this report]

Geoff Keston is the author of more
than 250 articles that help organizations find opportunities in
business trends and technology. He also works directly with clients to
develop communications strategies that improve processes and customer
relationships. Mr. Keston has worked as a project manager for a major
technology consulting and services company and is a Microsoft Certified
Systems Engineer and a Certified Novell Administrator.

return to top of this report]