Two places to start. You can enable ODBC tracing and/or use SQL Server Profiler.
ODBC tracing creates a huge amount of information. You really have to want to look at it because it's not pretty.
SQL Server Profiler will display the batches that are getting to SQL Server. If the batch doesn't get to SQL Server, you won't see it here.
-Mike
>I have a visual foxpro application that is using sql server as its database. Some of our users are experiencing difficulties connecting to sql server.
>
>They seem to make the connection to sql server , but are experiencing extreme difficulties when a sqlexec command is issued. For example:
>
>lcSQL = 'SELECT * FROM ' + lcTable
>
>lnSQLResult = SQLEXEC(gnConnectHandle, lcSQL, lcTempCursor)
>
>
>
>Some users experience no problems and others are finding that when the above code is issued , the system seems to hang.
>
>We are using TCP/IP protocol.
>
>Any suggestions would be greatly appreciated.
>
>Thanks
>
>Joyce