![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I am using Pervasive 7 and VB6.0. I am currently using the ODBC driver and Scalable SQL to run queries. Recently however we have been having problems with Scaleable and the ODBC hanging when one of the applications has a problem connecting, this hoses up all of the other applications except the ones running direct to BTRIEVE using BTRCALL (I assume). So I want to attempt to learn how to use the BTRCALL so my app won't get hosed up along with the rest of them. The question I have is that it appears to be wasteful to define the entire record in a TYPE DEFinition and retrieve the entire record, only to pluck out the stuff that you really need. Can you ask only for those fields of a record that you want, instead of the entire record with each call to BTRCALL? Thanks in advance, -Henry |
#3
| |||
| |||
|
|
Kind of. There are 3 options that I can think of: 1) If the parts of the record are the first x bytes of a record you can set the data buffer length to the number of bytes that you want to get. This will of course return a status code indicating that there are not enough bytes specified for the data buffer, but the number of bytes specified are returned, unless there is some other status code, e.g. 9, end of file 2) You can use chunk operations. With chunk operations you can specify an offset and a length. Chunk operations can be used for both reads and writes. 3) You can use extended operations. Extended operations are quite powerful. You can specify filters on keys or not (although not on a key will cause file scans. You can also specify the byte offset and lengths. It also allows returning multiple records (or sub-records) up to the 64KB data buffer size. You can also set reject counts but be careful of setting it too high as they can become blocking making other requests wait. Leonard On 8 Sep 2004 13:01:23 -0700, myfriendhenry (AT) yahoo (DOT) com (henry) wrote: I am using Pervasive 7 and VB6.0. I am currently using the ODBC driver and Scalable SQL to run queries. Recently however we have been having problems with Scaleable and the ODBC hanging when one of the applications has a problem connecting, this hoses up all of the other applications except the ones running direct to BTRIEVE using BTRCALL (I assume). So I want to attempt to learn how to use the BTRCALL so my app won't get hosed up along with the rest of them. The question I have is that it appears to be wasteful to define the entire record in a TYPE DEFinition and retrieve the entire record, only to pluck out the stuff that you really need. Can you ask only for those fields of a record that you want, instead of the entire record with each call to BTRCALL? Thanks in advance, -Henry |
![]() |
| Thread Tools | |
| Display Modes | |
| |