SQLAlchemy#

Binder

Capability

Support

Persistence

Files

Simulation

Cache

The SQLAlchemy wrapper can store ontology individuals using several tables on any of the database backends suported by SQLAlchemy. It is based on the rdflib-sqlalchemy package. The wrapper is included with SimPhoNy and available under simphony_osp.wrappers.SQLAlchemy.

[1]:
from simphony_osp.wrappers import SQLAlchemy

Configuration

The configuration string for the SQLAlchemy wrapper is an SQLAlchemy Database URL. To use the wrapper, just provide such an URL and the create argument.

[2]:
sqlalchemy = SQLAlchemy('sqlite:///database.db', True)

Tip

Check the SQLAlchemy documentation to learn how to construct database URLs.