<docbook><section><title>VirtBulkRDFLoaderExampleSingle</title><bridgehead class="http://www.w3.org/1999/xhtml:h2">Example for Single RDF Source File Upload</bridgehead>
<para>The following example demonstrates how to upload single RDF source file using the Bulk Loading Sequence.</para>
<para> </para>
<orderedlist spacing="compact"><listitem>Assuming there is a folder with name &quot;tmp&quot; in your FS and it is under a directory specified in the <emphasis><ulink url="http://docs.openlinksw.com/virtuoso/databaseadmsrv.html#fp_acliniallowed">DirsAllowed</ulink></emphasis> param defined in your virtuoso ini file.
</listitem>
<listitem>Also assume in the folder &quot;tmp&quot; there is a file named &quot;kidehen.n3&quot; that contains: <programlisting>&lt;http://www.openlinksw.com/dataspace/kidehen@openlinksw.com#this&gt; &lt;http://www.w3.org/1999/02/22-rdf-syntax-ns#type&gt; &lt;http://rdfs.org/sioc/ns#User&gt; .
&lt;http://www.openlinksw.com/dataspace/kidehen@openlinksw.com#this&gt; &lt;http://www.w3.org/2000/01/rdf-schema#label&gt; 	&quot;Kingsley&quot; .
&lt;http://www.openlinksw.com/dataspace/kidehen@openlinksw.com#this&gt; &lt;http://rdfs.org/sioc/ns#creator_of&gt; &lt;http://www.openlinksw.com/dataspace/kidehen@openlinksw.com/weblog/kidehen@openlinksw.com%27s%20BLOG%20%5B127%5D/1300&gt; .
</programlisting></listitem>
<listitem>Make sure the <ulink url="VirtBulkRDFLoaderScript">Bulk Loading script</ulink> is executed.
</listitem>
<listitem>Register the file &quot;kidehen.n3&quot; with graph IRI &quot;<ulink url="http://kidehen.com">http://kidehen.com</ulink>#&quot;: <programlisting>SQL&gt;ld_dir (&#39;tmp&#39;, &#39;kidehen.n3&#39;, &#39;http://kidehen.com#&#39;);
Done. -- 90 msec.
</programlisting></listitem>
<listitem>Create in the &quot;tmp&quot; folder an empty file with name: <emphasis>kidehen.ext.graph</emphasis> </listitem>
<listitem>Edit the <emphasis>kidehen.ext.graph</emphasis> by adding the graph IRI, so the content of the file to be: <programlisting>http://kidehen.com#
</programlisting></listitem>
<listitem>Finally execute: <programlisting>SQL&gt;rdf_loader_run ();
Done. -- 100 msec.
</programlisting></listitem>
<listitem>As result on the Server console should be shown notification for the loading is complete: <programlisting>10:21:50 PL LOG: Loader started
10:21:50 PL LOG: No more files to load. Loader has finished,
</programlisting></listitem>
<listitem>To check the inserted triples for the given graph, execute: <programlisting>SQL&gt;SPARQL
SELECT * 
FROM &lt;http://kidehen.com#&gt;
WHERE 
  {
    ?s ?p ?o
  }
;
  
s                                                                 p                                                 o
VARCHAR                                                           VARCHAR                                           VARCHAR
_______________________________________________________________________________
http://www.openlinksw.com/dataspace/kidehen@openlinksw.com#this   http://www.w3.org/1999/02/22-rdf-syntax-ns#type   http://rdfs.org/sioc/ns#User
http://www.openlinksw.com/dataspace/kidehen@openlinksw.com#this   http://www.w3.org/2000/01/rdf-schema#label        Kingsley
http://www.openlinksw.com/dataspace/kidehen@openlinksw.com#this   http://rdfs.org/sioc/ns#creator_of                http://www.openlinksw.com/dataspace/kidehen@openlinksw.com/weblog/kidehen@openlinksw.com%27s%20BLOG%20%5B127%5D/1300

3 Rows. -- 10 msec.
</programlisting></listitem>
</orderedlist></section></docbook>