Connecting to SQL Server 2008 from Java

前端 未结 3 1851
我寻月下人不归
我寻月下人不归 2020-12-06 08:20

I am trying to connect to SQL Server 2008 server from Java

here is a program

import java.sql.*;

public class connectURL {

    public static void m         


        
3条回答
  •  佛祖请我去吃肉
    2020-12-06 09:16

    I thing the connection URL may be wrong. Then try following connection,

     String Connectionurl="jdbc:sqlserver://localhost:1433;DatabaseName=YourDBName;user=UserName;Password=YourPassword"
    

提交回复
热议问题