This discussion is archived
4 Replies Latest reply: Oct 3, 2011 10:19 AM by sdas RSS

RDBMS and RDF- SparQL

880207 Newbie
Currently Being Moderated
Hi,

I have some data in RDBMS table's and some data stored as Triple in RDF tables. In my SparQL query, can i combine both RDBMS and RDF together in a single query?
if it is possible, it would be great if you can share some example.

I am looking for something like this, FIND SUPERVISOR NAME

RDBMS table- EMPLOYEE - contains all employee names
RDF table - EMPLOYEE_HEIRARCY - contains employee heirarcy
MODEL- MD_EMPLOYEE

SPARQL QUERY:

SELECT ?SUPERVISOR WHERE { ?SUPERVISOR :isSeniorOf ?EMPLOYEE  AND ?EMPLOYEE ='MH'}
above query is not correct query w.r.t to syntax, i m looking for such a logic taking employee name from rdbms table and heirarcy from rdf table in a single sparql query.

Thanks and Regards,
Manish Hardasmalani
  • 1. Re: RDBMS and RDF- SparQL
    sdas Journeyer
    Currently Being Moderated
    You can do this from a SQL query using SEM_MATCH table function which allows you to specify a SPARQL graph pattern.
    SEM_MATCH retrieves relevant data from the RDF store which can then be joined with one or more relational tables.

    For more details on use of SEM_MATCH, please refer to documentation at:
    http://download.oracle.com/docs/cd/E11882_01/appdev.112/e11828/sdo_rdf_concepts.htm#CHDJACII
  • 2. Re: RDBMS and RDF- SparQL
    880207 Newbie
    Currently Being Moderated
    Hi,

    I am using Jena & SparQL. I am not sure if i can call SEM_MATCH query directly from Jena. As per my understanding Sparql gets converted to SEM_MATCH query.
    As i am calling Sparql query using Jena, I want to use RDBMS table data also with sparql query in a single query.

    If possible , kindly share an example , it would be of great help

    Thanks and Regards,
    Manish H
  • 3. Re: RDBMS and RDF- SparQL
    880207 Newbie
    Currently Being Moderated
    Any view on above comment
  • 4. Re: RDBMS and RDF- SparQL
    sdas Journeyer
    Currently Being Moderated
    Use of SPARQL from Jena does not currently allow access to relational tables. A workaround you may consider trying would be to first generate RDF triples from the relational tables and then try querying using SPARQL the original RDF data plus the RDF data generated from relational tables.

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points