how to include database in the C # project and use it locally?

0

I have a system in C # for inventories that uses Sql server is already finished, but now if I want to sell or install it on another computer I would have to install sql server Express to the client and that does not fit me, as you do if you Are you trying to sell software with the database?

I would not be installing directly the client the sql server, what option do you give?

Thank you in advance for your comments.

    
asked by Manny 17.12.2018 в 23:30
source

2 answers

0

It depends a lot on the scenario you have. For example, if your system has a central DB that will be accessed by several clients in the same network or remotely, you can not save yourself from installing an engine. However, if your system is only used by one machine and on the same machine it should have its small DB, I would recommend replacing Sql Server with a Sqlite that allows you to have all the information stored in a single file that you can share in the same installer of the application.

    
answered by 17.12.2018 в 23:52
0

If your system is web, or server system, or the database is going to be consumed by many clients, it is best to install the SQL Server as you say.

If it is a desktop application where only this application will access the database, you can include an embedded database. This can be a SQL Server Compact Edition (I think it is discontinued, but it works very well and is compatible with most SQL Server code), or an SQLite (you should change the SQL code). There are other options but these are the best known or at least the ones I've worked with.

    
answered by 18.12.2018 в 07:32