freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: M C <mcbp223 AT yahoo.com>
- To: freetds AT lists.ibiblio.org
- Subject: [freetds] RE: textptr size in blob field
- Date: Thu, 25 Mar 2004 10:11:33 -0800 (PST)
> > > I am playing with Query Analizer as a server emulator.
> > For blobs, it will accept arbitrary lengths for textptr, less
> > than 256 of coarse (my tests were with the MS odbc driver and
> > oledb provider so far).
> > Would you please check the hardcoding in token.cpp, function
> > tds_get_data(), by the line
> > if (len == 16) { /* Jeff's hack */
> > tds_get_n(tds, blob_info->textptr, 16);
> >
> > and see if you can afford a dynamic size for that?
> > I'm not sure if you want to go for the allocation overhead
> > though, but some strategy with optimization for len <= 16 might work.
> > Thanks,
> > MC
> >
>
> ??? how did you send length for textptr ???
> textptr is not the content of text...
>
> freddy77
The byte preceeding textptr in the blob is it's length. It is gotten in
tds_get_data(),
switch (curcol->column_varint_size) {
case 4: /* Its a BLOB... */
----> len = tds_get_byte(tds);
blob_info = (TDSBLOBINFO *) &
(current_row[curcol->column_offset]);
----> if (len == 16) { /* Jeff's hack */
tds_get_n(tds, blob_info->textptr, 16);
tds_get_n(tds, blob_info->timestamp, 8);
But tested only against 16 in the if (len == 16).
I take it that textptr works like a bookmark, the server can send anything
and the client will send back the same thing when asking for a chunk.
MC
---------------------------------
Do you Yahoo!?
Yahoo! Finance Tax Center - File online. File on time.
-
[freetds] RE: textptr size in blob field,
M C, 03/25/2004
- Re: [freetds] RE: textptr size in blob field, Frediano Ziglio, 03/25/2004
- <Possible follow-up(s)>
- RE: [freetds] RE: textptr size in blob field, Lowden, James K, 03/25/2004
-
[freetds] RE: textptr size in blob field,
M C, 03/26/2004
- Re: [freetds] RE: textptr size in blob field, James K. Lowden, 03/27/2004
- [freetds] RE: textptr size in blob field, Mike C., 03/29/2004
- RE: [freetds] RE: textptr size in blob field, Lowden, James K, 03/29/2004
Archive powered by MHonArc 2.6.24.