Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1548
  • Last Modified:

Insert into Blob field in Interbase

I am trying to insert records into an Interbase table using the SQL syntax: INSERT INTO TABLE(Field list) VALUES(Value list). My code is choking on the BLOB field. I get the error:

SQLState: HY000
Native Error Code: 335544334
conversion error from string "BLOB"

Please help!!

Amy
0
AmyWiles
Asked:
AmyWiles
1 Solution
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
the BLOB fields cannot be inserted as usual fields, but need to be updated by chunks (AppendChunk) and also read by chunks (GetChunk).
You need to read some documentation about this, which is the same for all the databases with BLOB (or similar) data type. See here for ASP/Interbase/Blob sample:

http://www.sibprovider.com/en_us/faqs.asp#008

CHeers
0
 
AmyWilesAuthor Commented:
Could someone please give me an example of writing text to a blob field? I am having a hard time finding any examples.
0
 
dwhelpCommented:
Writing text to a BLOB field would be like

Recordset("fieldname").AppendChunk Fieldvalue

to retrieve,

Chunksize = Recordset("Fieldname).Actualsize
Fieldvalue = Recordset("Fieldname").GetChunk(Chunksize)

hope this helps, AmyWiles

0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now