-2

I have a nice program idea, it will be a very simple application that will save your username and password on a sql server database file, i know how to do it, but the problem is i don't want the client to install sql server in order to add or remove a record in database, besides i want my database file embedded into the application so the user have a single .exe file, i heard about a library called sqllite or something, it`s function is not to let the user install sqlserver to make the application work.

Yuck
  • 49,664
  • 13
  • 105
  • 135
R.Vector
  • 1,669
  • 9
  • 33
  • 41

6 Answers6

5

You can use SQLCE and search for SQLCE private deployment, basically it is a light weight of MS SQL on client side. With privatedeployment you just need to copy related DLLs to your project folder without installation.

hardywang
  • 4,864
  • 11
  • 65
  • 101
1

You are looking for SQL Server Compact edition.

Kirk Woll
  • 76,112
  • 22
  • 180
  • 195
1

As you mention, Sqlite is an option. It's a compact and file based database. No need for installing anything. The full database resides in a file. You'll need to reference the Sqlite database engine for connecting to it, however.

diggingforfire
  • 3,359
  • 1
  • 23
  • 33
  • can you mention how to do that ? as this is my first time embedding sql libraries and using them . – R.Vector Dec 28 '11 at 18:51
  • Just add a reference to the database engine I linked to. It's an ADO.NET adapter so you can just use SqlConnection, SqlCommand as you normally could. – diggingforfire Dec 28 '11 at 18:57
1

You need to use a file based SQL database.

There are several - most popular are:

See this SO question - Free portable database.

Community
  • 1
  • 1
Oded
  • 489,969
  • 99
  • 883
  • 1,009
0

I probably wouldn't use SQL at all if you are only going to create one table with a few (< 100) rows. Its way to much overhead for that small amount of information.

I would save the username and password in a file, then use the Enterprise Libraries Cryptography Application Block to secure the file.

You also most likely don't want the storage engine embedded into the exe, then your passwords are tied to that specific application on that specific computer. You will have to implement an import/export program anyway to move your info to another machine.

Check out http://keepass.info/

Jeremy Gray
  • 1,378
  • 1
  • 9
  • 24
0

Yes , you can implement it by

SQLite ,

SQL Server CE ,

Or Xml

And also , in my last project , the application call the webservice when need to access DataBase.

So , there are lots of ways to avoid install SQL Server on client PC .

shenhengbin
  • 4,236
  • 1
  • 24
  • 33