>Is it possible to acces SQL Server tables via VFP without using ODBC?
>OR at least without configure ODBC on each client station??
>If yes, how can I do that?
>Thank you in advance.
No for the first question, and yes for the second.
VFP can not access SQL Server directly. To access it, you have the following options:
1. SQL Pass-thru - uses ODBC driver to connect to SQL Server
2. ADO - can be congfigured to use either ODBC driver or OLE-DB provider
3. Remote Views - provides a VFP friendly wrapper to SQL Pass-thru so it uses ODBC
IAC, you need to install something on each client machine.
As for question 2, you do not need an entry in the ODBC Configurator to connect to SQL Server. Yo can use SqlStringConnect to get a valid remote handle. Try:
lcconn = [Database=]+tcDatabase+[;Server=]+tcDatabaseServer+[;Driver=SQL Server]
lcconn = lcconn + [;UID=]+tcUID+[;PWD=]+lcPWD
lnhandle = sqlstringconnect(lcconn)
where
tcDatabase is the database to connect to
tcDatabaseServer is the name or IP address of the server (provided you are using TCPIP to connect)
UID is the user ID to use to login to the database
PWD is the password
HTH.
Larry Miller
MCSD
LWMiller3@verizon.netAccumulate learning by study, understand what you learn by questioning. -- Mingjiao