Deploy application with database - c#

I am developping a C# 4.0 desktop application that uses a SQL Server Express 2005 database, currently it is located in the mssql data folder. My client's machine doesn't have SQL Server installed (it will need a license) and i can't use SQL Compact database because the data will pass the 3Go limit in the compact version, so my questions are :
Is it possible to install my app in the client machine without SQL Server being installed?
Can i include my database while deploying the app?
Can SQL Server be installed on my client's machine, if it has been checked in the prerequisites when deploying ?

Is it possible to install my app in the client machine without SQL
Server being installed?
It's depends, if the client is in the same LAN as your SQL DB server, then yes, otherwise, it is impossible to interact with remote SQL DB server if you're both not at the same network.
Can i include my database while deploying the app?
Yes you can, look here
Can SQL Server be installed on my client's machine, if it has been
checked in the prerequisites when deploying ?
There are light server versions for client environments, see SQL Server Express

Related

Publish ASP.NET MVC project with Local DB on a server that does not have SQL Server installed on it

I have developed an ASP.NET MVC 5 project, and I am using a local SQL Server database.
I want to publish that project on an IIS Local server, but this IIS local server does not have SQL Server. The SQL Server is not installed on that local server.
Can I publish project on that server or not?
Yes you can publish your app on your server which SQL Server is not installed on it; but you should have another server (at least) which the SQL Server is installed on that and set your app connection string on that server, so your project will be connected to the DB.
You can do that with cloud base services!
But you should be aware of security issues.
If you can not install SQL Server on your own server because of OS, low resources, maintenance issues and etc. this solution may be help you.
These two articles from Microsoft may be helpful:
1.
Connecting from Another Computer
2.
Import or link to data in an SQL Server database

Deploy winform application with sql server dependency

I've a winform application that intreacts with MS sql server for database. How can I deploy the winform application in any computer and make it runnable ? I'm not clear on how can we deploy sql server database to the client computer and make the application running.
You can convert to SQL Server LocalDB (https://msdn.microsoft.com/en-us/library/hh510202.aspx), which basically involves a changing your connection string and then deploying a copy of the .mdf file with your application. LocalDB will need to be installed on the user's computer.
MsSql Server has several editions with different constraints and requiring different configurations (https://www.microsoft.com/en-us/sql-server/sql-server-editions).
If you focus on standard, developer, enterprise, or web edition of MsSQL Server,
You need to deploy your database to a separate db server as a best practice, and your application connects it remotely by appropriate using connection string.
If you will use Ms Sql Express edition which you can deploy your database with your application together; in addition, you can prepare an installation package and attach the db to that installation process. You should keep in mind that Express edition has limitations such as storage.
If your applications is not stuck with Sql Server, you can take a look at alternative standalone databases such as sqllite. You can follow the thread for the details (Alternatives to SQLite?)

Database connectivity in windows form application

I have created a Billing Software using windows forms and sql server 2012.
Now i'm very confused over many things regarding database connectivity.
After making exe file, for installing in client machine i have to install sql server in client machine and configure the database then install my application.
My doubt is.. is this how this procedure works? I downloaded some billing software from internet and how they work without configuring a database? and which is the best practice? should i install sql server in client machine ?
If you just want a single standalone database per instance of the application - specific to the computer installed on - then you have a few options.
SQLite - https://sqlite.org/
SQL Server Express LocalDB (this is the 2016 version) -https://msdn.microsoft.com/en-us/library/hh510202.aspx
Both of these run stand alone databases that can be embedded into your program using visual studio. There are others, but these are the ones I'm familiar with.
Syntax for SQLite has some differences to its syntax (mostly package specific) however SQL Server Express LocalDB runs the same T-SQL as the standard SQL Server package
You do not have to install SQL Server on the client machine. The clients connect via network to the central database using some database client drivers.
Assuming that you are using ADO.NET then you have configure the clients somehow to use the right connection string, where server name, database name etc. is contained.

How to migrate from Microsoft SQL server database (on local machine) to LocalDB?

I have a simple web application that accesses tables in the Microsoft SQL server database installed locally on my laptop. But in order to run the application on every other laptop I have to migrate to localDB. Please suggest.!
Sorry if this is an obvious/dumb answer: The great value of web applications is that they can be accessed remotely by users who don't have to install anything to use them. Install your database and web application on a server and you can access it from anywhere.

Include SQL Server database in application

I have developed a c# application connected to a SQL Server 2008 database, and I want to make a project install. How can I include my database in the application without having to have SQL Server 2008 installed?
It is not possible. you better use SQL SERVER COMPACT EDITION, if you don't want to install sql server in client's system. Sql Server Compact edition enables you to create a local database that can be accessed without sql server. But using it you will not be able to use your application on networking.

Categories

Resources