How To Let the SPARQL Endpoint Save Results In WebDAV?

By default the SPARQL endpoint can only send the result back to the client. This might be inconvenient in case of the result is expected to be accessible from programs like File Managers or Archivers.

The solution is to let the Endpoint to create "Dynamic" resources in a WebDAV folder on the Virtuoso server. A WebDAV client, e.g. the built-in client of Windows Explorer, can then connect to that storage and to access these resources as if they were local files.

If you are the Database Administrator and you want to enable this feature, you should perform the following steps:

  1. Make sure the Web Service Endpoint runs under the "SPARQL" account. This user should have an access to WebDAV (U_DAV_ENABLE=1 in the Virtuoso DB.DBA.SYS_USERS) table.
  2. A WebDAV home directory (e.g. /DAV/home/SPARQL/ ) should be created and the path to it should be remembered in DB.DBA.SYS_USERS (U_HOME) field.
    • Note: do not forget to add the leading and the trailing slash chars.
  3. The home directory should contain a sub-directory with name "saved-sparql-results", and the sub-directory should have "DynaRes?" DAV Extension Type.

After the appropriate directory is set up correctly, the SPARQL Web Service Endpoint will then show additional options to choose how to save results.

Related