ActualSize returns -1 for Text fields
- From: "Rod da Silva" <RodDaSilva@xxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 23 Sep 2005 09:59:52 -0400
Hi all,
I have a table called 'mytable' with two fields in it Fld1, and Fld2. Fld1
is a text field and Fld2 is char(10) . If I create an ADORecordSet object
using the following query:
select * from mytable
I can't read the contents of the text field (Fld1). ActualSize of this
field is always -1 even though I can see the data in the table from SQL
Enterprise Manager. Same is true if I use the query explicitly listing the
fields:
select Fld1, Fld2 from mytable
** However *** if I query for:
select Fld2, Fld1 from mytable
it works (notice the field order is different)!! I can access the contents
of the Fld1 text field using this query.
So I do some digging on the internet and find out that this is a farily well
known issue. Text fields must be the last field in the field list of a
select statement to be returned properly. This is why the above workaround
(placing FLD1 last in the field list) works.
But while this workaround works in this trivial case, my real problem is
that I have tables with multiple text fields so there appears no single
query that will return all my text data.
My question is ... is there a hotfix for this?? I am running MDAC 2.8 RTM
under Windows 2000 against SQL Server Developer Edition ver (8.00 763
(SP3)).
I really need a fix for this since using varchar instead of text fields
isn't an option for me (I need CLOBs). Any help would be greatly
appreciated.
Rod
.
- Follow-Ups:
- Re: ActualSize returns -1 for Text fields
- From: Daniel Crichton
- Re: ActualSize returns -1 for Text fields
- From: Mark J. McGinty
- Re: ActualSize returns -1 for Text fields
- Prev by Date: Re: ADO Find Help?
- Next by Date: Re: Permissions???
- Previous by thread: Does Ado async fetching also good for processing as well?
- Next by thread: Re: ActualSize returns -1 for Text fields
- Index(es):
Relevant Pages
|
|