Blob & array datatypes are not supported for move operation

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Nols Smit
Posts: 15
Joined: Tue 11 Aug 2009 06:04

Blob & array datatypes are not supported for move operation

Post by Nols Smit » Tue 13 Oct 2009 09:57

Hi,

I have a demo database and program but can't submit it via the Contact window because I do not know where to look up my license number. My order reference number is 010278473, bought thru ComponentSource on 9/8/2009 5:38:15 PM. I have mailed them about the license number.

I'm using UniDac thru Delphi 7 to a Firebird version 2.1

Server version: WI-V2.1.2.18118 Firebird 2.1
Client version: 6.3

With IBObjects I can load a binary blob but not using UniDac, I get above mentioned error. How can I submit the demo program and Firebird database?

Regards,

Nols Smit

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Tue 13 Oct 2009 11:09

You get this error if DataType of the parameter is ftString.

You should set DataType to ftBlob or ftMemo. The correct DataType is set automatically if you use AsBlob or AsMemo properties.

Nols Smit
Posts: 15
Joined: Tue 11 Aug 2009 06:04

Post by Nols Smit » Tue 13 Oct 2009 11:51

Hi,

Thanks for the quick answer, perhaps it was to quick :)

Below is is the code i'm using.

Regards,

Nols Smit

with UniDocuments do
begin
Close;
ParamByName('DocType_ID').AsInteger := 1;
ParamByName('Writer_ID').AsInteger := 1;
ParamByName('Updater_ID').AsInteger := 1;
ParamByName('Description').AsString := 'WhatEver';
ParamByName('Document_Date').AsDateTime := DateTimePicker1.Date;
ParamByName('Tree_Projects_ID').AsInteger := 1;
ParamByName('Abstract').AsString := 'Whatever abstract';
ParamByName('Content').LoadFromStream(BigMs, ftBlob); {uses DB}
ParamByname('Filename').AsString := ApplicationPath + '\TestDoc.xls';
Execute;
end;

Below is the DDL of the table:

CREATE TABLE DOCUMENTS (
ID "ID_Key" NOT NULL /* "ID_Key" = INTEGER NOT NULL */,
DOCTYPE_ID "ID_Integer" NOT NULL /* "ID_Integer" = INTEGER */,
WRITER_ID "ID_Integer" NOT NULL /* "ID_Integer" = INTEGER */,
UPDATER_ID "ID_Integer" NOT NULL /* "ID_Integer" = INTEGER */,
TREE_PROJECTS_ID "ID_Integer" NOT NULL /* "ID_Integer" = INTEGER */,
DESCRIPTION VARCHAR100 NOT NULL /* VARCHAR100 = VARCHAR(100) */,
ABSTRACT "TextBlob" /* "TextBlob" = BLOB SUB_TYPE 1 SEGMENT SIZE 100 */,
DOCUMENT_DATE "DataDate" /* "DataDate" = DATE */,
RECORD_DATE "TIMESTAMP" /* "TIMESTAMP" = TIMESTAMP */,
CHANGE_DATE "TIMESTAMP" /* "TIMESTAMP" = TIMESTAMP */,
FILENAME VARCHAR100 /* VARCHAR100 = VARCHAR(100) */,
CONTENT BINARYBLOB /* BINARYBLOB = BLOB SUB_TYPE 0 SEGMENT SIZE 100 */
);

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Wed 14 Oct 2009 07:01

Use AsMemo instead of AsString for the Abstract parameter.

Nols Smit
Posts: 15
Joined: Tue 11 Aug 2009 06:04

Post by Nols Smit » Wed 14 Oct 2009 09:38

Hi,

It's working OK now. Thanks. :)


Regards,

Nols Smit :lol:

Post Reply