Does the Connection string support UNC paths?

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Does the Connection string support UNC paths?

cbgifford
I am old database programmer that just came across SQLite and am working on
a small project for a PVR that uses SQLite as it's db provider.  I try
specifying a UNC path to the database for the datasource in the connection
string and I get the following error, "unable to open database file".   .
When I look at the exception generated, I see an errorcode = 14.  However,
if I map a network drive, I can open the file and work with it.  I am
running Windows 7 x64 Pro and system.data.sqlite version 1.0.93.0 with dot
net framework 4.0 and Visual Studio 2010.

 

Obviously SQLite supports UNC paths because I am using SQLite database
browser to open the same database using a UNC path.

 

Any help would be apreicated, thanks!

 

 

_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: Does the Connection string support UNC paths?

Kevin Benson
On Sun, Sep 7, 2014 at 12:46 AM, Chris <[hidden email]> wrote:

> I am old database programmer that just came across SQLite and am working on
> a small project for a PVR that uses SQLite as it's db provider.  I try
> specifying a UNC path to the database for the datasource in the connection
> string and I get the following error, "unable to open database file".   .
> When I look at the exception generated, I see an errorcode = 14.  However,
> if I map a network drive, I can open the file and work with it.  I am
> running Windows 7 x64 Pro and system.data.sqlite version 1.0.93.0 with dot
> net framework 4.0 and Visual Studio 2010.
>
>
>
> Obviously SQLite supports UNC paths because I am using SQLite database
> browser to open the same database using a UNC path.
>
>
>
> Any help would be apreicated, thanks!
>

http://sqlite.1065341.n5.nabble.com/System-Data-SQLite-and-UNC-Paths-td72920.html

--
   --
      --
         --Ô¿Ô--
        K e V i N
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
ajm
Reply | Threaded
Open this post in threaded view
|

Re: Does the Connection string support UNC paths?

ajm
In reply to this post by cbgifford

>
> ---- Mensaje original ----
> De: "Chris" <[hidden email]>
> Para:  <[hidden email]>
> Fecha:  Sat, 6 Sep 2014 23:46:19 -0500
> Asunto:  [sqlite] Does the Connection string support UNC paths?
>
>
>
>I am old database programmer that just came across SQLite and am working on
>a small project for a PVR that uses SQLite as it's db provider.  I try
>specifying a UNC path to the database for the datasource in the connection
>string and I get the following error, "unable to open database file".   .
>When I look at the exception generated, I see an errorcode = 14.  However,
>if I map a network drive, I can open the file and work with it.  I am
>running Windows 7 x64 Pro and system.data.sqlite version 1.0.93.0 with dot
>net framework 4.0 and Visual Studio 2010.
>
>
>
>Obviously SQLite supports UNC paths because I am using SQLite database
>browser to open the same database using a UNC path.
>

Also, a full pathname, can start with a double backslash (\\), indicating the global root, followed by a server name and a share name to indicate the path to a network file server.

HTH.

--
Adolfo


_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: Does the Connection string support UNC paths?

cbgifford
In reply to this post by Kevin Benson
Thanks for the info.  I was unaware of the forum.  I've registered there now as well.

-----Original Message-----
From: [hidden email] [mailto:[hidden email]] On Behalf Of Kevin Benson
Sent: Sunday, September 07, 2014 1:43 AM
To: General Discussion of SQLite Database
Subject: Re: [sqlite] Does the Connection string support UNC paths?

On Sun, Sep 7, 2014 at 12:46 AM, Chris <[hidden email]> wrote:

> I am old database programmer that just came across SQLite and am
> working on a small project for a PVR that uses SQLite as it's db
> provider.  I try specifying a UNC path to the database for the datasource in the connection
> string and I get the following error, "unable to open database file".   .
> When I look at the exception generated, I see an errorcode = 14.  
> However, if I map a network drive, I can open the file and work with
> it.  I am running Windows 7 x64 Pro and system.data.sqlite version
> 1.0.93.0 with dot net framework 4.0 and Visual Studio 2010.
>
>
>
> Obviously SQLite supports UNC paths because I am using SQLite database
> browser to open the same database using a UNC path.
>
>
>
> Any help would be apreicated, thanks!
>

http://sqlite.1065341.n5.nabble.com/System-Data-SQLite-and-UNC-Paths-td72920.html

--
   --
      --
         --Ô¿Ô--
        K e V i N
_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


-----
No virus found in this message.
Checked by AVG - www.avg.com
Version: 2014.0.4765 / Virus Database: 4015/8169 - Release Date: 09/07/14


_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: Does the Connection string support UNC paths?

jose isaias cabrera
In reply to this post by ajm

[hidden email] wrote...

>
>>
>> ---- Mensaje original ----
>> De: "Chris" <[hidden email]>
>> Para:  <[hidden email]>
>> Fecha:  Sat, 6 Sep 2014 23:46:19 -0500
>> Asunto:  [sqlite] Does the Connection string support UNC paths?
>>
>>
>>
>>I am old database programmer that just came across SQLite and am working
>>on
>>a small project for a PVR that uses SQLite as it's db provider.  I try
>>specifying a UNC path to the database for the datasource in the connection
>>string and I get the following error, "unable to open database file".   .
>>When I look at the exception generated, I see an errorcode = 14.  However,
>>if I map a network drive, I can open the file and work with it.  I am
>>running Windows 7 x64 Pro and system.data.sqlite version 1.0.93.0 with dot
>>net framework 4.0 and Visual Studio 2010.
>>
>>
>>
>>Obviously SQLite supports UNC paths because I am using SQLite database
>>browser to open the same database using a UNC path.
>>
>
> Also, a full pathname, can start with a double backslash (\\), indicating
> the global root, followed by a server name and a share name to indicate
> the path to a network file server.

Just a little suggestion: UNC paths are slower than connecting that same
path to a drive.  If you are going to use it a lot, I suggest for you to
connect that path to a drive and it will be much faster.  We have a system
using SQLite with a SharedDB and connecting that path to a drive is much
faster.  Ihth.

josé

_______________________________________________
sqlite-users mailing list
[hidden email]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users