I'd like to know the best way to access virtuoso's webdav feature from a .NET Core web API?

@kidehen do I have to use vsp scripts or can I access it via the virtuoso driver on .NET?

WebDAV is an open standard; basically, and HTTP protocol extension. Thus, you simply interact with Virtuoso’s WebDAV functionality using an WebDAV client layer.

VSP (like ASP.NET, PHP, etc…) only comes into play if you are writing HTML based interfaces for your WebDAV client e.g., what we’ve done with the ODS-Briefcase component of ODS.


On going through the .NET based WebDAV client example above, I couldn’t find any specific connection to the virtuoso WebDAV repository . Could I get code snippets that shows this? Thank you @kidehen

A Virtuoso instance is an HTTP/WebDAV server. You connect to Virtuoso via WebDAV from Web DAV clients,

All you need is a host and endpoint. The Virtuoso WebDAV endpoint is http://{cname}:8890/DAV/, assuming Virtuoso is running on port 8890.

You can even mount Virtuoso’s WebDAV endpoint to your host operating system via its WebDAV support.


Thank you @kidehen. I’ve been able to connect to virtuoso WebDAV on my local host through the ODBC provider for ASP.NET. However, we have a virtuoso universal server instance at app.approvia.net and I’m having some trouble getting the correct connection string for making the connection through ODBC.

If you can make a localhost connection to WebDAV, then you must be able to connect to app.approvia.net if online and the relevant SQL port , 1111 I presume, for ODBC access is accessible from the .Net client the connection is being made from.

Thus how do the connect strings being passed for the localhost and app.approvia.net connection compare ie what are they ?

Here’s how I connected to the local host: OdbcConnection cnn = new OdbcConnection(“Driver={Virtuoso (Open Source)};Host=;Database=DB;Uid=dba;Pwd=dba;”)
I’d like to know how to connect to the app.approvia.net instance.

Assuming your app.approvia.net is a default Virtuoso installation would it not be obvious to use Host=app.approvia.net:1111;Database=DB;Uid=dba;Pwd=dba; for connecting to it ie replacing with its hostname , making sure its SQL port is accessible from your .Net client and not restricted by any firewall or security restrictions

My issue is with this part: {Virtuoso (Open Source)}. app.approvia.net is on the virtuoso universal server.

Virtuoso Open Source, Virtuoso Closed Source, Virtuoso Universal Server, etc are the same thing from an ODBC interface/connectivity view point and the same Virtuoso ODBC driver can be used to connect to either.

Thus have you actually tried making a connection to the app.approvia.net Virtuoso instance and if it is failing what is the actual error message being reported ?

ODBC is a Data Access Protocol that uses a Connection String comprising the following attributes to connect an ODBC-compliant app, service, or framework to an ODBC-compliant database management system:

Canonical Name (Host:Port), Database, Username (UID), Password (PWD) etc.

Example, assuming Virtuoso is listening on port 1111 for connections from SQL clients, as per INI file setting.


WebDAV is an HTTP-based protocol, so you would be connecting to that using the connection string pattern outlined above, bar a desire to interact with the underlying WebDAV system tables which isn’t advised at this stage – bearing in mind the fact that Virtuoso offers both a native WebDAV interface and APIs via its HTTP interface.

ASP.NET core offers HTTP interfaces through which you should be able to make WebDAV calls. Typically, that would be port 80 or 8890, subject to how you’ve configured HTTP services in your INI file.

When I use:
“Driver={Virtuoso (Open Source)};Host:8890=app.approovia.net;Database=DB;Uid=iam;Pwd=iam;”
I get this error:

ERROR [S2801] [OpenLink][Virtuoso ODBC Driver]CL033: Connect failed to app.approovia.net:8890 = app.approovia.net:8890

I’ve also tried port 80 for the same host and I get the same error.

You should be using Driver={Virtuoso (Open Source)};Host=app.approovia.net:1111;Database=DB;Uid=iam;Pwd=iam; , basically using the same connect string format that worked for your localhost connection …

I got the same error response:

ERROR [S2801] [OpenLink][Virtuoso ODBC Driver]CL033: Connect failed to app.approovia.net:1111 = app.approovia.net:1111

What OS are you running .Net on, is it Windows or other OS ?

I assume you have installed the Virtuoso ODBC Driver to make your successful localhost connection, in which case have you configured a basic ODBC connection with the ODBC Driver Manager to verify a basis direct ODBC connection can be made to the Virtuoso app.approovia.net:1111 instance you are seeking to connect to, as until that is possible you will not be able to connect from .Net.

Also, as asked previously have you verified the SQL port 1111 is accessible from remote locations and not blocked by firewall or other security restrictions ?

From my windows firewall logs, SQL port 1111 isn’t blocked. I also get the same error message when I try to establish a connection to app.approovia.net:1111 from the ODBC driver manager.

You need to start you Virtuoso instance in foreground debug mode so that its port bindings and related information are echoed to the screen while you attempt to connect from an ODBC client e.g., ODBC Driver Administrator.

Startup command:

virtuoso -c virtuoso.ini -f

When replying to this message, if you still can’t connect, please provide:

  1. Initial startup output from the virtuoso foreground debug output
  2. ODBC Data Source Name Configuration information covering host, port, and username

/cc @Joshua

When trying to run the command, I get the prompt: " ‘virtuoso’ is not recognized as an internal or external command, operable program or batch file."

Is there something I am missing?

I assume Virtuoso is running on Windows as indicated in previous posts ? In which you need to:

  1. Stop the Virtuoso Windows service if running

  2. Goto the Virtuoso Database Directory in C:\Program Files\OpenLink Software\Virtuoso 8.3\database by default

  3. Start the Virtuoso server in foreground debug mode with the command:

    …\bin\virtuoso-odbc-t -f -c virtuoso.ini