Skip to main content

rdf-sql-bulkloader

Project description

rdf-sql-bulkloader

Bulk load of SQL table from RDF in Python

Install

pip install rdf-sql-bulkloader

Usage (Command Line)

rdf-sql-bulkloader load-sqlite  -o cl.db cl.owl

Note: currently only sqlite supported

Usage (Programmatic)

See tests

Core table

CREATE TABLE statement (
	id TEXT,
	subject TEXT,
	predicate TEXT,
	object TEXT,
	value TEXT,
	datatype TEXT,
	language TEXT,
        graph TEXT
);

Prefixes

this uses the merged prefixmap from prefixmaps by default

This can be overridden programmatically when instantiating a loader, e.g

Explicit map:

loader = SqliteBulkloader(path=path, prefix_map={...})

Using pre-registered:

loader = SqliteBulkloader(path=path, named_prefix_maps=["obo", "prefixcc"])
  • TODO: add override from CLI

Acknowledgements

This work was entirely inspired by James Overton's [rdftab.rs](https://github.com/ontodev/rdftab.rs

This cookiecutter project was developed from the sphintoxetry-cookiecutter template and will be kept up-to-date using cruft.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rdf-sql-bulkloader-0.1.1.tar.gz (5.0 kB view details)

Uploaded Source

Built Distribution

rdf_sql_bulkloader-0.1.1-py3-none-any.whl (5.9 kB view details)

Uploaded Python 3

File details

Details for the file rdf-sql-bulkloader-0.1.1.tar.gz.

File metadata

  • Download URL: rdf-sql-bulkloader-0.1.1.tar.gz
  • Upload date:
  • Size: 5.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.13

File hashes

Hashes for rdf-sql-bulkloader-0.1.1.tar.gz
Algorithm Hash digest
SHA256 0d73ffce11bf1020867a1459f8bb1cfdd263b69cafe9d12a91e79ac8b1a2b741
MD5 bca46f5e25d79f4e437c53fa1bd90dde
BLAKE2b-256 96079ee970720ac46438ff7b64472cc504a759d9568083f47b5fc66d37b78212

See more details on using hashes here.

Provenance

File details

Details for the file rdf_sql_bulkloader-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for rdf_sql_bulkloader-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 64e6bc95170ffe87b8438330abdbdd4063746f7c18f27561dee7330dcc7f2b66
MD5 aac7ff0bb21a17909fa6da5b9b2e5c1e
BLAKE2b-256 220d2bbf79a44c3b2ad50c249023f9328e3544c836d8eb4610b33de73f93d868

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page