App not working on other PC without SQL Server - sql-server

I have created an app in Visual Studio using VB.Net and SQL Server database and the app is running fine on my PC but when I use this app on another PC it runs fine but wherever is database required it gives me error. Please let me know do I need to install SQL Server on those PC where I want to use this app? Or is there any other alternate way?
Please help I'm a beginner at programming.

It sounds like your application is using the SQL Server Native Client for its connections. You can read more about it here: https://msdn.microsoft.com/en-us/sqlserver/aa937733.aspx
In short, you'll need to have people install the client on their machine, or use a different method to connect to the database.

Related

SQL Server Express installation required for clients connecting to a server?

I would like to know if an installation of SQL Server Express is required on my client PCs? I have searched a fair bit and so far all I've seen were related to attached databases or local databases.
Here's the setup of my system.
There will be a Windows Server PC that will be hosting the SQL Server instance.
Client PCs will be running a VBNet based windows form application where connection strings will be fed to table adapters that would allow them to connect to the server.
Now I have tested running the application on a Windows 7 PC without SQL Server Express installed and it works, connection was a success and data can be retrieved etc. However the system is actually going to be run on Windows XP when it goes live.
So I was wondering if the client PCs would require an installation of SQL Server Express or any sort of dlls for it to be able to connect to the server? Or would the .Net Framework be sufficient?
Thanks in advance.
You will not require a SQL instance on your client PCs. The app can just make the connection to the server via the connection strings. Our app is very similar in the fact that we support Windows Xp and SQL Server 2005 and it works well without any instance on the client PCs. We do install a local instance on the client but this is only used when transferring data to a laptop so it can be used when disconnected from the network. HTH
I think you should install .Net framework on your client pc. I'm not entirely sure if it's the case but to be sure, run it on a Windows XP machine. If you dont have an xp machine, try using desktop simulater like virtualbox of sorts.

Unable to connect to sql database server

Yesterday, I installed SQL Server 2008 on my PC. It was working perfectly, but now when I am trying to connect to the database engine, it generates this error:
Try using this.
This will only work if you are trying to connect to the database on the same machine. If you are writing software to connect to a remote database, you will need to work out what the connection string needs to be. This website may help you. ConnectionStrings

c# WinForm - Pre-requisite for running Oracle Database Access

I've a Windows Form c# application which uses Oracle.DatabaseAccess.dll for communicating with oracle database.
After generating a MSI and installing on my laptop everything works great.
However when I try to install the same application on my colleague's laptop the connection doesn't work. It shows incompatible provider.
Could someone please help me out where can I get the pre-requisites for running application that uses oracle database?
I suspect it runs fine on my machine as I've installed oracle express database. But I don't want to install this on all machine where this application needs to be run.
Thank you.

Strange situation regarding connection to SQL Server with JDBC

I have an application that I have developed 2 years ago that stopped working due to not be able to connect to a remote SQL Server 2008 anymore, and I can't figure it out why this is happening.
This is the situation: I have a desktop where I have jdk1.6.0_31 and I developed a small 'helloworld' like application to test the connection to this remote SQL Server, even with the firewall off I can't make it connect. Still on this desktop I have Visual Studio where I'm able to connect to this SQL Server (so firewall is not the problem I guess).
I have a laptop where I tested this 'helloworld' JDBC app, and on this laptop the application works, and I just copied the app from the desktop to the laptop.
I also copied the app to my virtual server (that hosts the application that I developed 2 years ago) and there this 'helloworld' app does not work also, with firewall on or off, it doesn't matter.
So I'm wondering, what in the world could be leading to such a strange situation? JDBC on desktop does not work, but through visual studio it does, JDBC on laptop works, and JDBC on virtual server does not?? I'm really confused about this. I have been struggling with this for a week already. And that's why I really need your help people!!
Best regards and thanks in advance!
Bruno
I expect this is as simple as a connection string issue. The format for a connection string might change for different languages (Java vs C#). Can you please post the connection string you are using -- rename constants of course -- I just want to see the format you are using.

Asp.net MVC database connection setting in Visual studio 2008

I am trying to learn Asp.net MVC framework. I was looking at the video tutorial at the link below
http://www.asp.net/learn/mvc-videos/video-395.aspx
In this video the very first step is to add a new database to the example application.
I have visual studio installed on my development machine but the SqlServer Express is running on a different machine, so when I try and add a new database following the same steps as the video I get the following error
"Connections to SQL Server files(*.mdf) require SQL express 2005 to funciton properly. Please verify the installation of the component or download from the url"
I am assuming this is because Visual studio is looking for an instance of SQL express on my local machine and since it doesnt exist on the local machine,it errors out.
So how do i tell visual studio, to connect to a different machine and create the database there?
I am using Visual studio 2008 with .net 3.5 Sp1
Make sure that remote connections is enabled in your sql server express installation (http://www.linglom.com/2007/08/31/enable-remote-connection-to-sql-server-2005-express/). Then take a look at www.connectionstrings.com for the various ways to connect to the sql server as appropriate for your environment. Then configure the connectionstrings section in web.config and reference that configuration target when connecting to the db.
Alternatively you might try using LINQ to SQL which will streamline some of these tasks (still need to enable remote connections and get an appropriate connection string defined...LINQ to SQL wizard for the rest).
Open the Server Explorer and add a new Data connection. Same thing as adding a new .mdf. You can use it just the same.
create the database on the remote computer(edit: IIRC, you can also create it within visual studio when you add the connection)
ensure that it allow remote connections
add the connection in database explorer
I'm not sure what's happening in that video, but if you for instance are going to use linq2sql, visual studio will add the connectionstring to web.config when you drag the tables into the .dbml :)
What you'll have to do is attach the mdf to the database server you have running on your separate machine, and then open up your server explorer and navigate to that particular machine and select the database from there.
I am not going to see the video so I can't tell you what step to change. But it should be easy enough to write a connection string (or get it off the web) that connects to a database on the remote computer and not your PC.
I am so used to writing my own connection strings that I don't even know of any option in VS that automates this.
Instead of add a new database to a remote machine as you indicated on your local machine, you can try to create the database on the remote machine firstly, and then connect to that remote database within your visual studio.

Resources