Translating WFS Query to SQL/XML Query



Similar documents
Translating WFS Query to SQL/XML Query

INTEGRATION OF XML DATA IN PEER-TO-PEER E-COMMERCE APPLICATIONS

Unraveling the Duplicate-Elimination Problem in XML-to-SQL Query Translation

DEVELOPMENT OF THE INTEGRATING AND SHARING PLATFORM OF SPATIAL WEBSERVICES

Query reformulation for an XML-based Data Integration System

Join Minimization in XML-to-SQL Translation: An Algebraic Approach

Constraint Preserving XML Storage in Relations

Data interchange between Web client based task controllers and management information systems using ISO and OGC standards

Schema mapping and query reformulation in peer-to-peer XML data integration system

Quality Assessment for Geographic Web Services. Pedro Medeiros (1)

Managing a Geographic Database From Mobile Devices Through OGC Web Services

Enforcing Data Quality Rules for a Synchronized VM Log Audit Environment Using Transformation Mapping Techniques

Model-Mapping Approaches for Storing and Querying XML Documents in Relational Database: A Survey

Constraint-Based XML Query Rewriting for Data Integration

About scope of OpenGIS technology in oceanographic data management and visualization Andrey V. Golik, Vitaly K. Fischenko, Stepan G.

Technologies for a CERIF XML based CRIS

Visualization Method of Trajectory Data Based on GML, KML

Web Map Context Service for Adaptive Geospatial Data Visualization

Open Geospatial Consortium, Inc.

Toward the Automatic Derivation of XML Transformations

ArcGIS Framework Plug-In: Extending the ArcGIS Desktop for ANSI Standard Framework Data to Support Government Decision Making

National Geothermal Data System and Global Geosciences Data Integration

The Virtual Database A Tool for Integrated Data Processing in a Distributed Environment

ACE GIS Project Overview: Adaptable and Composable E-commerce and Geographic Information Services

Chapter 1: Introduction

A Hybrid Architecture for Mobile Geographical Data Acquisition and Validation Systems

Providing GRASS with a Web Processing Service Interface

Integrating Heterogeneous Data Sources Using XML

DISMAR implementing an OpenGIS compliant Marine Information Management System

Interoperable Solutions in Web-based Mapping

CURSO Inspire INSPIRE. SPEAKER: Pablo Echamendi Lorente. JEUDI 23/ THURSDAY 23 rd W S V : G E O S P A T I A L D A T A A C C E S S

Applying Semantic Web Technologies in Service-Oriented Architectures

reviewed paper Proceedings REAL CORP 2009 Tagungsband April 2009, Sitges.

OData Extension for XML Data A Directional White Paper

Linking Sensor Web Enablement and Web Processing Technology for Health-Environment Studies

Data Quality in Information Integration and Business Intelligence

REAL-TIME DATA GENERALISATION AND INTEGRATION USING JAVA

SQL SUPPORTED SPATIAL ANALYSIS FOR WEB-GIS INTRODUCTION

Access to ESPON Database by third- party applications An expertise on the potentialities of web services for accessing the ESPON metadata and data

Semantic Web Technologies and Data Management

Querying Combined Cloud-Based and Relational Databases

A View Integration Approach to Dynamic Composition of Web Services

GIS Databases With focused on ArcSDE

Big Data Analytics. Rasoul Karimi

GIS AS A DECISION SUPPORT FOR SUPPLY CHAIN MANAGEMENT

ISO and OGC Service Architecture

Pennsylvania Geospatial Data Sharing Standards (PGDSS) V 2.5

Data Integration using Semantic Technology: A use case

Distributed GML Management with SVG Tools

Rich Web Map Applications HANNES JOHANSSON

mdwfs Model-driven Schema Translation for Integrating Heterogeneous Geospatial Data

A MEDIATION LAYER FOR HETEROGENEOUS XML SCHEMAS

KEYWORD SEARCH IN RELATIONAL DATABASES

Luc Boerboom 1, Özgün OskayAlan 2. P.O. Box 217, 7500 AE Enschede, The Netherlands,

A View Integration Approach to Dynamic Composition of Web Services

ADVANCED GEOGRAPHIC INFORMATION SYSTEMS Vol. II - Using Ontologies for Geographic Information Intergration Frederico Torres Fonseca

Introduction to the Mapbender OWS Security Proxy

Integrating AJAX Approach into GIS Visualization Web Services

Oracle8i Spatial: Experiences with Extensible Databases

A generic approach for data integration using RDF, OWL and XML

Catalogue or Register? A Comparison of Standards for Managing Geospatial Metadata

Introduction to Geospatial Web Services

Modern Databases. Database Systems Lecture 18 Natasha Alechina

14 Databases. Source: Foundations of Computer Science Cengage Learning. Objectives After studying this chapter, the student should be able to:

An architecture for open and scalable WebGIS

Data Visualization Using Web GIS Software

Presentation / Interface 1.3

Supporting Database Provenance under Schema Evolution

Webservices Technological Evolutions. Peter Bogaert University of Ghent (Belgium) E Governement Academy 8 Geoservices 15 februari 2006 Kortrijk.

Transcription:

Translating WFS Query to SQL/XML Query Vânia Vidal, Fernando Lemos, Fábio Feitosa Departamento de Computação Universidade Federal do Ceará (UFC) Fortaleza CE Brazil {vvidal, fernandocl, fabiofbf}@lia.ufc.br Abstract. The purpose of the WFS specification, proposed by the the OpenGIS Consortium (OGC), is to describe the manipulation operations over geospatial data using GML. Web servers providing WFS service are called WFS Servers. WFS servers publish GML views of geographic features stored in data sources such that the user can query and update data sources through a user defined feature type schema. In this work, we study the problem of answering WFS queries through a feature type schema, when the data is stored in a relational database. A feature type is specified by the feature type schema and a set of correspondence assertions. The feature type's correspondence assertions formally specify relationships between the feature type schema and the relational database schema. We define the semantic for WFS query answering and present an algorithm that translate a WFS query defined over a feature type schema into a SQL/XML query defined over the relational database schema. 1. Introduction The mission of the OpenGIS Consortium (OGC) [8] is to promote the development and use of advanced open system standards and techniques in the geoprocessing area and related information technologies. Two important OGC's initiatives are: the Geography Markup Language (GML) [9] and the Web Feature Service (WFS) [11]. The purpose of the WFS specification is to describe the manipulation operations over geospatial data using GML. Their objective is to provide queries, updates and exchange of geospatial data as geographic features instances encoded in GML. According to OGC, a geographic feature is an abstraction of a real world phenomenon associated with a location relative to the Earth. It is possible to describe the feature form and localization through its geometric attributes, remaining the other attributes to represent its non-geographic properties. Given that, WFS servers publish GML views of geographic features stored in data sources such that the user can query and update data sources through the feature type schema According to WFS specification [11], the requests supported by a WFS Server must be as follow: 1. DescribeFeatureType: Retrieves the XML [20] schema of the feature types.

2. GetFeature: Retrieves feature instances of a feature type. It is possible to apply selection filters on the GetFeature request. Those filters are specified by OGC in [7] and enclose logical, arithmetical and space conditions. 3. LockFeature: Allows blocking a feature type while it is being updated. It is optional. 4. Transaction: Allows updating feature types. It is optional. 5. GetCapabilities: Retrieves a list of feature types serviced by the WFS Server and what operations are supported on each feature type. In this work, we study the problem of answering WFS queries through a feature type schema, when the data is stored in a relational database. In this work, a feature type is specified by the feature type schema and a set of correspondence assertions [13,14,18]. The feature type's correspondence assertions formally specify relationships [6,14] between the feature type schema and the relational database schema. We show that, based on the feature type correspondence assertions, one can efficiently translate WFS query to SQL/XML query. SQL/XML [16] is an ANSI and ISO standard that provides support for using XML in the context of an SQL database system. The SQL/XML standard is being developed under the auspices of INCITS Technical Committee H2 as a new part (Part 14) of the SQL standard and is aligned with SQL:2003 [2]. SQL/XML is simple, highly intuitive and, in some development scenarios, is an ideal way of returning relational data. Moreover, we can apply XSL transformation on the XML result. To the best of our knowledge, there is no work on translating WFS query to SQL/XML query. There is a vast amount of work on XML-to-SQL translation [3,5,15]. Since WFS query is more restricted than XML queries, the approach proposed here is simpler and more efficient. The Deegree WFS [1], which is an open source implementation of the WFS Specification, in case where the feature has complex properties, it reformulates a WFS query into several SQL queries, each of which will compute the value of a complex property. So, our solution, which translates to only one SQL/XML query, is much more efficient than Deegree's approach. The main contributions of the paper are. We propose the use of correspondence assertions as the formalism to specify the mapping between a XML schema and a relational database schema. We formally specify the conditions for a set of correspondence assertions to fully specify a feature type in terms of relational database and, if so, we show that the mappings defined by the feature type correspondence assertions can be expressed as an SQL/XML query. We propose an algorithm that, based on the feature type s correspondence assertions, generates an SQL/XML query that constructs <featuremember> elements from the

corresponding tuples of relational database. We note that other mapping formalisms are either ambiguous or require the user to declare complex logical mappings [4,23]. We define the semantic for WFS query answering and present an algorithm that translate, based on the feature type correspondence assertions, a WFS query defined over a feature type schema into a SQL/XML query defined over the relational database. Moreover, we formally justify that SQL/XML query generated by the algorithm is a correct translation. The paper is organized as follows. Section 2 presents our mapping formalism. Section 3 discusses how to specify a Feature Type using correspondence assertions. Section 4 presents the semantic for WFS query answering and present an algorithm that translates a WFS query to a SQL/XML query. Finally, Section 5 contains the conclusions. 2. Correspondence Assertions In this section, let R1,...,Rn be relation schemes of a relational schema S. Let R1,...,Rn be relations over R1,...,Rn, respectively. Definition 2.1: Let fk be a foreign key of R1 that references R2. Assume that fk is of the form R 1 [a 1,...,a m ] R 2 [b 1,...,b m ]. (i) fk is a link from R1 to R2, and the inverse of fk, denoted fk -1, is a link from R2 to R1. (ii) Let r 1 be a tuple of R 1. Then r 1 /fk = { r 2 r 2 R 2 and r 1.a i = r 2.b i, 1 i m }; (iii) Let r2 be tuple of R2. Then r2/fk -1 = { r1 r1 R1 and r1.ai = r2.bi, 1 i m }. Definition 2.2: Let l be a link from R 1 to R 2, and let r 1 and r 2 be tuples of R 1 and R 2, respectively. We say that: (i) r1 references r2 through l iff r2 r1/l. (ii) l is single occurrence iff a tuple of R1 can reference at most one tuple of R2 through l. Otherwise, l is multiple occurrence. Definition 2.3: Let l 1,..., l n-1 be links. Assume that l i is a foreign key of the form R i [a 1 li,...,a mi li] R i+1 [b 1 li,...,b mi li] or the inverse of a foreign key of the form R i+1 [b 1 li,...,b mi li] Ri[a1 l i li,...,am i ], for 1 i n-1. (i) ϕ = l 1.....l n-1 is a path from R 1 to R n, and the tuples of R 1 reference tuples of R n through ϕ. (ii) ϕ is single occurrence iff li is single occurrence, for 1 i n-1.otherwise, ϕ is multiple occurrence. (iii) Let r1 be a tuple of R1. Then, r1/ϕ = { rn ( r2 R2)... ( rn Rn ) (ri.ak l i = ri+1.bk l i, for 1 k mi and 1 i n-1)}.

of feature type instance. (2) The correspondence assertions of the feature type are generated by matching the feature type XML schema and the relational database schema. (3) Based on the feature type correspondence assertions, GML Publisher generates the SQL/XML query that computes the extension of the feature type, and the SQL/XML sub-query that computes the value of each feature type path expression. Acknowledgments This work is financed by CNPq and project GML Publisher: Um Framework para Publicação de Feições Geográficas como GML (process no. 478571/2004-6). References 1. Deegree. http://deegree.sourceforge.net (visited on September 26th, 2005). 2. Eisenberg, A., Melton, J., Kulkarni, K., Michels, J.E. and Zemke, F. (2004) SQL:2003 has been published. In: SIGMOD Record, v.33, p.119-126. 3. Fernández, M., Kadiyska, Y., Suciu, D., Morishima, A., and Tan, W. C. (2002) SilkRoute: A framework for publishing relational data in XML. In: TODS, v.27, n.4, p.438 493. 4. Hernández, M. A., Miller, R. J., Haas, L. M. (2001) Clio: A Semi-Automatic Tool For Schema Mapping. In: SIGMOD Conference. 5. Krishnamurthy, R., Kaushik, R., and Naughton, J. F. (2003) XML-SQL Query Translation Literature: The State of the Art and Open Problems. In: XSym. 6. Madhavan, J., Bernstein, P., Rahm, E. (2001) Generic Schema Matching with Cupid. In: 27th Proceedings of the International Conference on Very Large Databases (VLDB), p.49 58. 7. OpenGIS Consortium. Filter Encoding Implementation Specification: Version 1.1. http://www.opengis.org (visited on September 26th, 2005). 8. OpenGIS Consortium. http://www.opengis.org (visited on September 26th, 2005). 9. OpenGIS Consortium. Schema for Geography Markup Language (GML). Version 2.0. http://www.opengis.org (visited on September 26th, 2005). 10. OpenGIS Consortium. Simple Features Implementation Specification for SQL. Version 1.1. http://www.opengis.org (visited on September 26th, 2005). 11. OpenGIS Consortium. Web Feature Service (WFS) Implementation Specification. Version 1.0. http://www.opengis.org (visited on September 26th, 2005). 12. Oracle Corporation. Disponível em: http://technet.oracle.com. (Acessado em 24 de abril 2005). 13. Popa, L., Velegrakis, Y., Miller, R. J., Hernandez, M. A., Fagin, R. (2002) Translating Web Data. In: Proceedings of the International Conference on Very Large Data Bases (VLDB), p.598 609.

14. Rahm, E., Bernstein, P.A. (2001) A Survey of Approaches to Automatic Schema Matching. In: VLDB Journal, v.10, n.4, p.334 350. 15. Shanmugasundaram, J., Kiernan, J., Shekita, E., Fan, C., and Funderburk, J. (2001) Querying XML views of relational data. In VLDB. 16. SQL/XML. http://www.sqlx.org/ (visited on September 26th, 2005). 17. Vidal, V. M. P., Feitosa, F. B. (2004) GML Publisher: Um Framework para Publicação de Feições Geográficas como GML. In: III Workshop of Theses and Dissertations on Databases, 19th Brazilian Symposium on Databases. Brasília, Brazil. 18. Vidal, V.M.P., Boas, R. V. (2002) A Top-Down Approach for XML Schema Matching. In: Proceedings of the 17th Brazilian Symposium on Databases. Gramado, Brazil. 19. Vidal, V.M.P., Casanova, M.A., Lemos, F.C. (2005) Automatic Generation of XML Views of Relational Data. In: Technical Report (http://lia.ufc.br/~arida). Universidade Federal do Ceará, November, 2005. 20. World-Wide Web Consortium. XML Schema Part 0: Primer Second Edition. http://www.w3.org/tr/xmlschema-0/ (visited on September 26th, 2005). 21. World-Wide Web Consortium. XQuery: An XML Query Language. Version 1.0. http://www.w3.org/tr/xquery/ (visited on September 26th, 2005). 22. World-Wide Web Consortium: XML Path Language (XPath). Version 1.0. http://www.w3.org/tr/xpath (visited on September 26th, 2005). 23. Yu, C., Popa, L. (2004) Constraint-Based XML Query Rewriting For Data Integration. In: SIGMOD, p.371 382.