Top

Name

DB.DBA.RDF_TRIPLES_TO_RDF_XML_TEXT — Serializes vector of triples into a session, in RDF/XML syntax.

Synopsis

DB.DBA.RDF_TRIPLES_TO_RDF_XML_TEXT ( inout triples any ,
  in print_top_level any ,
  inout ses any );
 

Description

Serializes vector of triples into a session, in TURTLE syntax. In current version, every triple is printed in separate top-level record (say, in rdf:Description tag), without any pretty-print or nesting optimization.

Parameters

triples

vector of triples in 'long valmode'.

print_top_level

zero if only rdf:Description tags should be written, non-zero if the rdf:RDF top-level element should also be written

ses

an output stream in server default encoding

Examples

Example 24.270. Simple example

create procedure simple_test(in query varchar, in dflt_graph varchar)
{
declare ses, rset, triples any;
declare txt varchar;
ses := string_output ();
rset := DB.DBA.SPARQL_EVAL_TO_ARRAY (query, dflt_graph, 1);
triples := dict_list_keys (rset[0][0], 1);
DB.DBA.RDF_TRIPLES_TO_RDF_XML_TEXT (triples, 1, ses);
txt := string_output_string (ses);
dump_large_text (txt);
}
;