Can't connect my desktop application to local SQL Server 2008 Express - sql

I am using SQL Server authentication for login through SQL Server Management Studio and I can access SQL Server. However, my desktop application cannot establish a connection to the server. I use the following connection string:
Server=PC-ADMIN\SQLEXPRESS; Database= Cafe; User=name; Pwd=password;
Please help.

Related

Connecting to SQL Server via DBeaver instead of SQL Server Management Studio

I am trying to connect to SQL Server using Windows authentication in DBeaver. Although I can easily connect via SQL Server Management Studio, DBeaver is generating a connection error:
No sqljdbc auth in java.library.path
Not sure why unlike DBeaver, SQL Server Management Studio can connect without any problem, but is there any instruction on how to ensure right JDBC driver (I think 32 bit) is installed and configured so I can connect via DBeaver?
Version 6.3.5.202002151353

SQL Server 2008 Express Management Studio connects to database from LAN but using same connection string vb.net application fails to connect

I developed an application using vb.net that connects to SQL Server Express 2008 R2 database (Hospital) through LAN, from a client PC.
SQL Server 2008 Express Management Studio successfully connects to the database (Hospital), but using the same connection string, my vb.net application fails to connect.
My connection string is:
"Data Source=TCP:192.168.1.1\SQLEXPRESS;Initial Catalog=Hospital;Persist Security Info=True;User ID=XXXX;Password=1111"
What is the problem? Can anybody help me to solve that?
First create a ODBC connection.
Then follow this connection string:
Data Source="SERVERNAME";Initial Catalog="DATABASE NAME";User ID="USERNAME";Password="PASSWORD";
IT should Work

Cannot connect to sql server 2008 using JDBC

I have tried all the methods to connect to the server.I am using sql server 2008 on mixed authentication mode.I can login via the sql server management studio using the sa login.But when I try accessing the same db from my java program I get the following error:
SQL Exception: com.microsoft.sqlserver.jdbc.SQLServerException: Login failed for user 'sa'. ClientConnectionId:191d94bb-a55e-47a0-bb9f-b84638313cf4
This is my connectionstring:
Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver");
String connectionUrl= "jdbc:sqlserver://localhost;databaseName=Northwind;user=sa;password=sa;";
I have accessed my database in the same way. One of my problems were that I hadn't enabled the port and IP for the database. Check these options in SQL Server Configuration Manager. Hope this helps =)

SQL Server 2008 erroneously returning SQL Authentication failed

I am attempting to connect to SQL via SQL authentication. On SQL Server I receive Login succeeded, yet via code I get Login failed for user 'geneva'. I verified the login in SSMS and am able to connect via Windows authetnication. The sql user has full rights. Tried via java/.net code, really unsure why I am unable to connect via SQL Auth.
Data Source=server;Initial Catalog=GenevaWorkflow;User ID=user;Password=password
The environment is SQL Server 2008/Windows 2008. Very frustrating being all I want is to connect via SQL authentication and SQL Server I set to mixed mode authentication.
Enable sql logins in server properties (from management studio) and restart sql server.

Sql server authentication Issue

In sql server 2005,
I could not connect to sql server in 'sql server Authentication' mode but i could connect in windows authentication mode.
The Username and password are also correct.
The Error says:
A connection was successfully established with the server, but then an error occured during the login process.(provider: shared memory provider, error:0-No process is on the other end of the pipe) (microsoft sql server: error:233)
May be the server is not configured to use both windows and sql server authentication modes