Hello all,
Have any way to connect to MSSQL server 2005/2008 using Trusted_Connection or Integrated
Security (Windows authentication)?
Best regards.
MS SQL 2005 - Windows authentication
-
- User
- Posts: 16
- Joined: Fri Jul 16, 2010 3:54 pm
Re: MS SQL 2005 - Windows authentication
I did through odbc, that worked ok for me.
Re: MS SQL 2005 - Windows authentication
Hello noorderling, Thanks for your reply,
did you make a connection to MSSQL using ODBC with Windows authentication?
can you post your code?
Thank you.
did you make a connection to MSSQL using ODBC with Windows authentication?
can you post your code?
Thank you.
=D
-
- User
- Posts: 16
- Joined: Fri Jul 16, 2010 3:54 pm
Re: MS SQL 2005 - Windows authentication
It's a 2-step thing:
First the hard part: make a user-odbc* with the help of odbc manager, and save it.
This is where you select if network login or user/pass is used to access the database.
You can validate the login here before saving.
This part I did not by coding, but manually in systemmanager.
In PB than initialize the odbc driver by useodbcdatabase().
You than call opendatabase(#db, "odbc-name just created", user, pass) with nullstring or empty string for user/pass.
* or machine if it is to be for every user on that machine.
First the hard part: make a user-odbc* with the help of odbc manager, and save it.
This is where you select if network login or user/pass is used to access the database.
You can validate the login here before saving.
This part I did not by coding, but manually in systemmanager.
In PB than initialize the odbc driver by useodbcdatabase().
You than call opendatabase(#db, "odbc-name just created", user, pass) with nullstring or empty string for user/pass.
* or machine if it is to be for every user on that machine.