>>Hi,
>>
>>In addition to the time out you set for your SQL Server connection in your VFP application, does SQL Server itself set a time limit on the connection? And how do you determine if your connection has timed out? For example, say at the top of the application or a module you connect to SQL Server and get a connection handle. Then you pass this connection handle to SQLEXE() function. Which fails if your connection is timed out. So I guess the failure of SQLEXE will tell your application that connection has timed out. Is there another method to determine it?
>>
>>TIA.
>
>Dmitry,
>
>There's difference between ConnectTimeOut and IdleTimeout (there's also QueryTimeout)
>
>
>Once you have the connection handle, you can set its IdleTimeout and QueryTimeout
>
>=sqlsetprop(connectionHandle, 'IdleTimeout', 0) && zero = default and indefinitely
>
>
>QueryTimeout is how long it can take for a query to return results. 0 or indefinitely is also the default
>
>
>The default for indefinite is 15 secs ( so I read in the help >> SQLSETPROP)
Thank you, Gregory. But what I don't understand is when I set the IdleTimeout to 10 and then wait a minute (greater than 10 seconds) and then call SQLEXE() with the connection handle I get no error and the data is returned. The way I understand IdleTimeout (from you message and the VFP Help) is the handle obtained initially should be invalid and I should get an error. What am I missing?
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham