rainspider
13th November 2009, 04:56
Windows + qt 4.6.0 for opensource+ nmake
when i using ADO connection string, field.
eg:
Provider=SQLOLEDB.1;User ID=sa;Password=123456;Initial Catalog=NorthWind;Data Source=127.0.0.1
But use this connectionstring (come form qt help document),successful .
eg:
DRIVER={SQL Server};SERVER=127.0.0.1;UID=sa;PWD=12345;DATABASE =NorthWind
code:
QSqlDatabase db = QSqlDatabase::addDatabase("QODBC");
db.setDatabaseName("connectionstring");
Who can tell me the difference between them ,or Where can i find the instructions on the connectionstrings?
when i using ADO connection string, field.
eg:
Provider=SQLOLEDB.1;User ID=sa;Password=123456;Initial Catalog=NorthWind;Data Source=127.0.0.1
But use this connectionstring (come form qt help document),successful .
eg:
DRIVER={SQL Server};SERVER=127.0.0.1;UID=sa;PWD=12345;DATABASE =NorthWind
code:
QSqlDatabase db = QSqlDatabase::addDatabase("QODBC");
db.setDatabaseName("connectionstring");
Who can tell me the difference between them ,or Where can i find the instructions on the connectionstrings?