Link to home
Start Free TrialLog in
Avatar of Clever_Bob
Clever_BobFlag for Australia

asked on

I can't work out the connection string for this DB

Hi. So I have this horrible SQLite database that I connect to fine using this monstrosity of a connection string...

What should I use instead for a relative pathway to my database that I can use to publish to a server please??

<add name="SQLiteEntities" connectionString="metadata=res://*/Model1.csdl|res://*/Model1.ssdl|res://*/Model1.msl;provider=System.Data.SQLite;provider connection string="data source=C:\Users\Rob\Dropbox\Rob Businesses\Bribie Indoor soccer\Bribie website\WaqarOctober2014\Soccer\Soccer\App_Data\1.080000.sql"" providerName="System.Data.EntityClient" /></connectionStrings>
Avatar of Dave Baldwin
Dave Baldwin
Flag of United States of America image

What programming language are you using?  I suggest you click on "Request Attention" to get that added to your Topic Areas so you will have a better chance of someone knowing what you need.  Also remove 'MySQL' because that has nothing to do with your question.
Avatar of Clever_Bob

ASKER

Thanks Dave - I'm using Visual Basic but the connection string should be the same across Visual Studio and more. There was no option for SQLite and I wanted to make it obvious that it was a database question, hence the MySQL inclusion.
ASKER CERTIFIED SOLUTION
Avatar of Dave Baldwin
Dave Baldwin
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
try

http://www.connectionstrings.com/sqlite/

SQLite.NET

Basic

Data Source=c:\mydb.db;Version=3;


Version 2 is not supported by this class library.
 
SQLite 



In-Memory Database

An SQLite database is normally stored on disk but the database can also be stored in memory. Read more about SQLite in-memory databases here.
 
Data Source=:memory:;Version=3;New=True;

 
SQLite 



Using UTF16

Data Source=c:\mydb.db;Version=3;UseUTF16Encoding=True;

 
SQLite 



With password

Data Source=c:\mydb.db;Version=3;Password=myPassword;

  

Open in new window