-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhttp%3A%2F%2Fwww.metaphacts.com%2Fresource%2Fadmin%2FDataImportExport.html
61 lines (59 loc) · 4.4 KB
/
http%3A%2F%2Fwww.metaphacts.com%2Fresource%2Fadmin%2FDataImportExport.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
<bs-row>
<bs-col sm=8 sm-offset=2 >
<ol class="breadcrumb" style="background:white;border:none;padding-left:0px;">
<li>
<semantic-link title="System Settings" uri="http://www.metaphacts.com/resource/admin/">System Settings</semantic-link>
</li>
<li class="active">Data Import and Export</li>
</ol>
<h2>Data Import</h2>
<hr/>
<bs-alert bs-style="info">
<strong>Info!</strong><br/>
<p>
Please be aware of that the simple file import via drag&drop should only be used for smaller files.
</p>
<p>
All communication is done over HTTP and such there are several limiting parameters, for example,
the maximum body size a client may post against the webserver (e.g. tomcat, jetty or nginx default configuration is usually around 2 MBs). <br/>
For loading larger datasets it is generally recommended to work either directly on the backend interface (e.g. Blazegraph) or to load the data via dedicated (but usually proprietary) triple store APIs. See also <semantic-link uri="http://help.metaphacts.com/resource/WorkingWithData"></semantic-link>.
</p>
</bs-alert>
RDF files can be uploaded using drag&drop field below. <br/>
Clicking into the field will open the browser's default file selector.<br/>
<mp-rdf-upload></mp-rdf-upload>
<h2>Data Export & Deletion</h2>
<hr/>
<semantic-query query='SELECT (COUNT(DISTINCT ?g) as ?number) WHERE{ GRAPH ?g {?s ?p ?o} } LIMIT 1'
template='{{#each bindings}}{{#ifCond number.value ">=" 1000}}<bs-alert bs-style="warning"> The following table is limited to show only <strong>1000</strong> named graphs.</bs-alert> {{number.value}} {{else}} <bs-alert bs-style="info"> The repository contains <strong>{{number.value}}</strong> distinct named graphs.</bs-alert> {{/ifCond}}{{/each}}'
>
</semantic-query>
<semantic-table config='{
"query":"SELECT DISTINCT ?graph WHERE {
GRAPH ?graph {?subject ?predicate ?object }
} LIMIT 1000",
"columnConfiguration" : [
{"variableName":"graph", "displayName":"Named Graph", "cellTemplate":"<semantic-link uri=\"[[resolvePrefix "Admin:NamedGraphs"]]\" urlqueryparam-graph=\"{{graph.value}}\">{{graph.value}}</semantic-link>"},
{"displayName":"Triples", "cellTemplate":"<semantic-query query=\"SELECT DISTINCT (COUNT(*) as ?number) WHERE{ GRAPH <{{graph.value}}>{?s ?p ?o} } LIMIT 1\"></semantic-query>"},
{"displayName":"Export", "cellTemplate": "<bs-dropdown-button id=\"download\" bs-size=\"xsmall\" title=\"\" class=\"mp-rdf-graph-action__download-dropdown\" no-caret=\"true\">
<bs-menu-item event-key=1>
<mp-graph-store-action title=\"Download\" action=\"GET\" graphuri=\"{{graph.value}}\" file-ending=\"trig\" class=\"mp-rdf-graph-action__download-dropdown-item\">TRIG</mp-graph-store-action>
</bs-menu-item>
<bs-menu-item event-key=2>
<mp-graph-store-action title=\"Download\" action=\"GET\" graphuri=\"{{graph.value}}\" file-ending=\"ttl\" class=\"mp-rdf-graph-action__download-dropdown-item\">TURTLE</mp-graph-store-action>
</bs-menu-item>
<bs-menu-item event-key=3>
<mp-graph-store-action title=\"Download\" action=\"GET\" graphuri=\"{{graph.value}}\" file-ending=\"nt\" class=\"mp-rdf-graph-action__download-dropdown-item\">NTRIPLES</mp-graph-store-action>
</bs-menu-item>
<bs-menu-item event-key=4>
<mp-graph-store-action title=\"Download\" action=\"GET\" graphuri=\"{{graph.value}}\" file-ending=\"rdf\" class=\"mp-rdf-graph-action__download-dropdown-item\">RDF/XML</mp-graph-store-action>
</bs-menu-item>
<bs-menu-item event-key=4>
<mp-graph-store-action title=\"Download\" action=\"GET\" graphuri=\"{{graph.value}}\" file-ending=\"owl\" class=\"mp-rdf-graph-action__download-dropdown-item\">OWL</mp-graph-store-action>
</bs-menu-item>
</bs-dropdown-button>" },
{"displayName":"Delete", "cellTemplate": "<mp-graph-store-action title=\"Delete\" data-action=\"DELETE\" data-graphuri=\"{{graph.value}}\"><i class=\"fa fa-trash-o \"></i></mp-graph-store-action>" }
]
}'></semantic-table>
</bs-col>
</bs-row>