=encoding utf8
=head1 NAME
rdf/examples/parser-store-sparql - updating and querying a store with SPARQL
=head1 SYNOPSIS
from rdf import RDFStore, TurtleParser, sparql_query, sparql_update;
let store := RDFStore.temp();
store.install_schema();
( new TurtleParser() ).parse_string( """
@prefix ex: <http://example.com/> .
ex:alice ex:name "Alice" .
""", into: store );
sparql_update( store, """
PREFIX ex: <http://example.com/>
INSERT DATA { ex:alice ex:knows ex:bob . }
""" );
let result := sparql_query( store, """
PREFIX ex: <http://example.com/>
ASK { ex:alice ex:knows ex:bob . }
""" );
say result{boolean} ? "yes" : "no";
=cut
modules/rdf/examples/parser-store-sparql.zzm
rdf-0.0.3 source code
Package
- Name
- rdf
- Version
- 0.0.3
- Uploaded
- 2026-06-12 23:55:02
- Repository
- https://github.com/tobyink/zuzu-rdf
- Dependencies
-
-
std/data/xml>= 0 -
std/data/xml/escape>= 0 -
std/data/json>= 0 -
std/db>= 0 -
std/digest/sha>= 0 -
std/getopt>= 0 -
std/internals>= 0 -
std/io>= 0 -
std/math>= 0 -
std/proc>= 0 -
std/string>= 0 -
std/time>= 0 -
std/uuid>= 0
-
- Metadata
- zuzu-distribution.json
- Archive
- Download .tar.gz