Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I connect to SQL Server 2K in PowerBuilder 10

Status
Not open for further replies.

flwk69

Programmer
Jan 5, 2006
3
I am migrating a PB 4 application TO PB 10 and we are using MS SQL SERVER 2000. How do you connect to a SQL 2K database inside of your app? What DSN do I use, (i.e. ODBC, OR OLE) to connect? Do I have to build a DSN? Does the OLEDB DLL file come with PB10? What do I have to do?

Please Advise!
 
We use OLE DB. Load the drivers from the PB installation CDs. We also use NT authentification so we don't have to provide user ids and passwords to connect.

This is a sample of our connection syntax:

// Profile sql03_dev - corpurch
SQLCA.DBMS = "OLE DB"
SQLCA.AutoCommit = False
SQLCA.DBParm = "PROVIDER='SQLOLEDB',DATASOURCE='sql03\dev',PROVIDERSTRING='database=cpr_cnb;Trusted_Connection=Yes'"

Matt

"Nature forges everything on the anvil of time
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top