SqlConnection oSQLConn = new SqlConnection();
oSQLConn.ConnectionString = "Data Source=(local);" +
                            "Initial Catalog=mySQLServerDBName;" +
                            "Integrated Security=SSPI";see
http://www.able-consulting.com/dotnet/adonet/Data_Providers.htm#SQLClientManagedProvider

解决方案 »

  1.   

    SqlConnection oSQLConn = new SqlConnection("Data Source=134.242.6.200;DataBase=LogManage;Uid=sa;Pwd=888;")
      

  2.   

    这段话是不是这样写啊,为什么还有错
    con.ConnectionString = "Data Source=(local);Initial Catalog=northwind;Integrated Security=SSPI";
      

  3.   

    什么错? 在什么环境下(webform or winform)出错?
      

  4.   

    这多半是SQL服务器的原因在企业管理器中,你可以删除目前的登陆代理,然后新建一个还不清楚就到数据库专栏看看!
      

  5.   

    SQL应该不会有问题啊,我用混合验证的方式就很好啊,难道MS对自己的数据库都不支持
      

  6.   

    你都没说什么错,别人怎么帮你?你要在webform里用的话,启动IIS的Integrated Authentication,然后在web.config里加
    <configuration>
       <system.web>
          <identity impersonate="true" />
       </system.web>
    </configuration>
      

  7.   

    Data Source=(local)data source=你的计算机名再看看
      

  8.   

    就是暴无法登陆的错误,我在公司里面试的时候是数据库的字段名可以在WEBFORM里面看的到,但是就是不能填充数据集,一填充几暴错,用混合验证就很好,就是不能用集成验证