Empty Blob field and access violation

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
ben
Posts: 119
Joined: Wed 17 Nov 2004 19:48

Empty Blob field and access violation

Post by ben » Tue 22 Feb 2005 00:32

Hello,

I have a TMyQuery and on AfterScroll I have the code:

var
M: TMemoryStream;
begin
M := TMemoryStream.Create;
Query.GetBlob('myblob').SaveToStream(M);


the code works fine if myblob has data. If its empty it returns an access violation. Is it a bug?

Thanks

Ikar
Posts: 1693
Joined: Thu 28 Oct 2004 13:56

Post by Ikar » Tue 22 Feb 2005 12:12

Please specify the exact MyDAC version (3.X.XX.XX) that you use.

> If its empty

Do you mean IsNull or BLOB of null length?

ben
Posts: 119
Joined: Wed 17 Nov 2004 19:48

Post by ben » Sun 27 Feb 2005 10:47

3.50.0.16 version

and the BLOB is just NULL, never filled with data.

Ikar
Posts: 1693
Joined: Thu 28 Oct 2004 13:56

Post by Ikar » Mon 28 Feb 2005 07:31

We couldn't reproduce the problem.
Please send us (mydac*crlab*com) complete small sample to demonstrate it and include script to create server objects.

Post Reply