LinuxCommandLibrary

rdfproc

Process and query RDF data stores

TLDR

Query RDF store

$ rdfproc [store] query sparql - "[SELECT * WHERE { ?s ?p ?o }]"
copy
Parse RDF file
$ rdfproc [store] parse [file.rdf]
copy
Serialize to format
$ rdfproc [store] serialize ntriples
copy
Add statement
$ rdfproc [store] add [subject] [predicate] [object]
copy
Print all statements
$ rdfproc [store] print
copy

SYNOPSIS

rdfproc [options] store command [args]

DESCRIPTION

rdfproc is a command-line utility for processing RDF data using the Redland RDF library. It can parse, store, query, and serialize RDF data.

PARAMETERS

parse file

Parse and load RDF file.
query lang uri query
Execute query.
serialize format
Output in format.
print
Print all statements.
add s p o
Add triple.
remove s p o
Remove triple.

EXAMPLES

$ # Create store and parse file
rdfproc mystore parse data.rdf

# SPARQL query
rdfproc mystore query sparql - "SELECT * WHERE { ?s ?p ?o } LIMIT 10"

# Serialize as N-Triples
rdfproc mystore serialize ntriples

# Add triple
rdfproc mystore add "http://example.org/s" "http://example.org/p" "value"

# Print all
rdfproc mystore print
copy

FORMATS

$ rdfxml   - RDF/XML
ntriples - N-Triples
turtle   - Turtle
copy

CAVEATS

Part of Redland RDF libraries. Stores are persistent by default. Use - for stdin/stdout.

HISTORY

rdfproc is part of Redland RDF Libraries by Dave Beckett, providing RDF processing since 2000.

SEE ALSO

rapper(1), roqet(1), redland(3)

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community