PRB: SQL PacketSize Property May Not Work w/Individual Handles (137536)
The information in this article applies to:
- Microsoft Visual FoxPro for Windows 3.0
- Microsoft Data Access Components 2.5
This article was previously published under Q137536 SYMPTOMS
After you use the SQLSETPROP command to change the packet size of an ODBC
connection, the SQLGETPROP command for the packet size returns the original
value of the packet size. The expected behavior is that SQLGETPROP would
return the new packet size as set in the SQLSETPROP command.
CAUSE
This behavior occurs because some drivers and servers do not support
changing the packet size on an active connection. In these situations, it
is necessary to change the default packet size prior to making each
connection. This is discussed in detail in the "Workaround" section of this
article.
RESOLUTION
The following workaround precludes setting up ODBC data sources connect1
and connect2. These can be SQL, Oracle, or other ODBC connections.
Use the following commands to set individual packet sizes:
=SQLSETPROP(0,'packetsize',8192) && 0 means default handle
handle1=SQLCONNECT('connect1','username','password')
paksize1=SQLGETPROP(handle1,'packetsize')
NOTE: packsize1 will return 8192
=SQLSETPROP(0,'packetsize',4096) && 0
handle2=SQLCONNECT('connect2','username','password')
paksize2=SQLGETPROP(handle2,'packetsize')
NOTE: packsize2 will return 4096
STATUS
This behavior is by design.
Modification Type: | Major | Last Reviewed: | 10/15/2003 |
---|
Keywords: | kbprb KB137536 |
---|
|