Home > database >  12.5 pb sql2008 via ado.net connection problem
12.5 pb sql2008 via ado.net connection problem

Time:10-10


//ADO.NETThe sqlca. DBMS="ADO.NET"//interface description 
The sqlca. LogID="id"
The sqlca. LogPass="PWD"
The sqlca. The AutoCommit=false//Settings are automatically submit
The sqlca. DBParm="Namespace='System. The Data. SqlClient', Integrated Security=false, DataSource='" + ls_ip +"', the Database='" + ls_dbname + "' "



In the development environment pb12.5 SQL2008 via ado.net connection is normal, but there is no installation of PB in computer tip:

ADO.NET DBMS is not supported in your current installation.



When it released this kind of situation, how to deal with? Online didn't find relevant information
?



==

CodePudding user response:

The best is to use a connection STRING

CodePudding user response:

https://bbs.csdn.net/topics/390165727

CodePudding user response:

Oh, processing is completed, I changed to direct all these STRING connection, mainly annoying pop-up login window when error, modified only set parameters error pop-up messagebox

CodePudding user response:

Or I can't, pb + ado.net to connect to the database, in the development environment can connect, on the client (not installed pb) cannot use ado.net,

Tip: DBMS, ADO.NET is not supported in your current installation.

CodePudding user response:

String ls_DBParm, ls_date
Boolean lb_conn
N_tr lt_tmp
If lt_tmp=sqlca_tmp then
Goto lb_connect
End the if
//check whether have the same connection and connection
Ls_DBParm=sqlca_tmp. DBParm
If isnull (ls_DBParm) then ls_DBParm='
Lb_conn=false
If ls_DBParm="ConnectString='Driver={SQL Server}; Server="+ as_server +"; The Database="+ as_db +"; Uid="+ as_user +"; The Pwd="+ as_pwd +"; ', DisableBind=1, StaticBind=0, CallEscape='No', DelimitIdentifier='Yes', StripParmNames=' Yes' "then
The select arjun ydate into: ls_date from (select the convert (char (10), getdate (), 121) as mydate) using a sqlca_tmp;
If sqlca_tmp. Sqlcode=0 then
Lb_conn=true
End the if
The else
Messagebox (" warning ", "connect the target database is different from the current, to prevent data errors, please exit log in again!" )
End the if
If lb_conn then return 1
//perform connection

Lb_connect:
Sqlca_tmp=create n_tr
Sqlca_tmp. DBMS="ODBC"
Sqlca_tmp. The AutoCommit=False
Sqlca_tmp. DBParm="ConnectString='Driver={SQL Server}; Server="+ as_server +"; The Database="+ as_db +"; Uid="+ as_user +"; The Pwd="+ as_pwd +"; ', DisableBind=1, StaticBind=0, CallEscape='No', DelimitIdentifier='Yes', StripParmNames=' Yes'
"CONNECT USING sqlca_tmp;
If sqlca_tmp. SQLCode=0 then
Return 1
The else
Return to 5
End the if


CodePudding user response:

The who has a solution, ADO.net SQL 2008 r, using PB12.5 pbPack12.5 automatically generated inside the dynamic library, some can even on the client, some of the building Lord shown above error, the client is win8.1 just may install w8.1 version there are differences, also cannot connect the client installed sqlncli64 client also not line, tried a lot of methods are not???????

CodePudding user response:

Building Lord: please install sqlncli64. Msi, sql2008 client, if it doesn't work, please copy the following file to c: \ Windows \ syswow64 directory is ok, I am so solve
  • Related