Board index » delphi » Help! Interbase array fields

Help! Interbase array fields

My interbase DB contains array fields. Whenever I try to add data to the
field I get
"Variant method calls not supported". I am updating the field as follows:

tblMyTable['Name'].AsString[i] := RecArray.Name[i];
also tried:
tblMyTable['Name'][i].AsString := RecArray.Name[i];

Could someone please tell me what I am doing wrong? It's probably something
simple
and most definitely stupid <grin>.

Thanks.

----------------------------------------------------------------------------
--
Rod Cullison - RCul...@worldnet.att.net
----------------------------------------------------------------------------
--

 

Re:Help! Interbase array fields


Quote
Rod Cullison wrote:

> My interbase DB contains array fields. Whenever I try to add data to
> the field I get
> "Variant method calls not supported". I am updating the field as
> follows:

> tblMyTable['Name'].AsString[i] := RecArray.Name[i];
> also tried:
> tblMyTable['Name'][i].AsString := RecArray.Name[i];

> Could someone please tell me what I am doing wrong? It's probably
> something simple
> and most definitely stupid <grin>.

Array fields are not supported by the BDE and Delphi.

--

Robert Schieck
-----------------------------------------------------------------------
MER Systems Inc.

Client/Server Development and Training using Delphi,  InterBase and
Oracle

InterBase page  http://www.mers.com/interbase.html
udflib page     http://www.mers.com/product.html
TDUG page       http://www.mers.com/tdug.html      -Toronto Delphi Users Group

Re:Help! Interbase array fields


I have never used Interbase array fields, and steered away from them for
one simple reason:  You cannot update a single array element
independently, you have to write to every element in the array no matter
how many you want to update.  I think the requirements are so stringent
as to require you to update the array field in one pass with a variable
dimensioned to the same as the array field in the table.  This is
detailed in the InterBase help file.  It's really buried, and I can't
remember where it is.

Charles
crobi...@mindspring.com

Other Threads