Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[protege-discussion] DataMaster - mapping columns to class members

Daramola Wande dwande at gmail.com
Thu Mar 27 15:23:29 PDT 2008


Dear Csongor,
thanks a lot your suggestion worked for me correctly.
regards.

On 3/27/08, Csongor Nyulas <csongor.nyulas at stanford.edu> wrote:
>
> Daramola Wande wrote:
>
>
> Dear Csongor,
> I am trying to query my ontology using the protege 3.3.1 java API in
> Netbeans 5.5.1
> .  The imported libraries list below are being reported as not found even though I have included all the jar files in the Protege folder in my classpath, including the Plugins folder.
>
>
> Besides the jar files from the Protege directory you have to include in
> the CLASSPATH the *jar files from the
> [PROTEGE_DIR]\plugins\edu.stanford.smi.protegex.owl directory*. NOT the
> directory itself but all the jar files contained in that specific directory.
>
> This should solve your problem.
> Regards,
> Csongor
>
>
> *import edu.stanford.smi.protegex.owl.model.OWLModel;
> import edu.stanford.smi.protegex.owl.model.OWLNamedClass;
> import edu.stanford.smi.protegex.owl.ProtegeOWL;*
> The one being recognized by my netbeans is:
> *import edu.stanford.smi.protege.model.*; *which is* * the frame-based
> one.
> What more do I need to do, this is the only error in my code for now.
> thanks for quick response.
> Regards.
>
> Wande.
>
> On 3/21/08, Csongor Nyulas <csongor.nyulas at stanford.edu> wrote:
> >
> > Dear Paul,
> >
> > There is no direct way to create instances of your arbitrary classes in
> > the ontology from your DB tables,
> > because there is no way to specify the mappings between the data source
> > elements and ontology elements. Although
> > we may build something that facilitate the ontology database mapping,
> > this will eventually happen in the
> > distant future when we will need this functionality in our project.
> >
> > Until then, there are a few tricky ways to achieve what you need.
> > Depending on at which end of the import
> > (DB or ontology) you have liberty of making (temporary) changes, you can
> > try:
> > a) the solution proposed by Jonathan
> >
> > b) in case you can't change your DB but can make changes in your
> > ontology:
> >     - import the structure of the database in a temporary ontology, in
> > order to check the names of the classes
> > and properties. Pay attention also to the generated namespaces
> >     - rename the classes and properties in your ontology to exactly
> > match (including the namespaces) the structure
> > in the temporary ontology
> >     - import the instances in your ontology using DataMaster
> >     - rename the classes/properties in your ontology to their original
> > names
> > This solution is good if you do not have too many tables, and you do not
> > have to repeatedly import from the database
> >
> > c) in case neither a) or b) is convenient import the instances in your
> > ontology with DataMaster and use the
> > ProtegeScriptTab, or SQWRL rules to create corresponding instances in
> > your original ontology structure.
> >
> > I hope this was helpful,
> >
> > Csongor
> >
> >
> > Paul Smith wrote:
> > > Thanks,
> > >
> > > perhaps I am not yet fully acquainted with DataMaster Plugin. The
> > problem is
> > > that when I import instances from a MySQL table into a Protégé class X
> > , it
> > > creates a new subclass Y, named after the table,  and fill it with the
> > > instances. How to import instances directly in class X then?? but what
> > is
> > > worse, class Y has an entire new set of attributes, named after the
> > table
> > > columns, whereas I wanted the attributes of X be filled. In other
> > words I need
> > > to map the table columns to the attributes of class X. How to do
> > this?? Please
> > > relief my struggle…
> > >
> > > ..Paul
> > >
> > >
> > > _______________________________________________
> > > protege-discussion mailing list
> > > protege-discussion at lists.stanford.edu
> > > https://mailman.stanford.edu/mailman/listinfo/protege-discussion
> > >
> > > Instructions for unsubscribing:
> > http://protege.stanford.edu/doc/faq.html#01a.03
> > >
> >
> > _______________________________________________
> > protege-discussion mailing list
> > protege-discussion at lists.stanford.edu
> > https://mailman.stanford.edu/mailman/listinfo/protege-discussion
> >
> > Instructions for unsubscribing:
> > http://protege.stanford.edu/doc/faq.html#01a.03
> >
>
> ------------------------------
>  _______________________________________________ protege-discussion mailing list protege-discussion at lists.stanford.edu https://mailman.stanford.edu/mailman/listinfo/protege-discussion  Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03
>
>
>
> _______________________________________________
> protege-discussion mailing list
> protege-discussion at lists.stanford.edu
> https://mailman.stanford.edu/mailman/listinfo/protege-discussion
>
> Instructions for unsubscribing:
> http://protege.stanford.edu/doc/faq.html#01a.03
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.stanford.edu/pipermail/protege-discussion/attachments/20080327/5051f4f3/attachment.html>


More information about the protege-discussion mailing list