Dataabstract datmemo problem in D10.4 sp3

in D10.3.3 with roda 10.0.0.1463 the save of an empty memo fiels works as expected
in D10.4.0 sp3 with roda 10.0.0.1481 this fails with the error
‘Invalid variant type (1) for Blob’
thrown in procedure VariantToWriter(aDataType : TDADataType; const aSourceVariant : Variant; aWriter : TWriter);
that is UDABinAdapter…

when tracing down the problem the variant value of the memo field in 10.3 is ‘unassigned’ as in 10.4 it is ‘Null’
since variantowriter only supports empty or 8209, this results in the DAError above…

i’ve compared both source versions but do not see a change that could result int the ‘null’ value
so the question is of this is a RODA problem or an issue in D10.4.0 ?

since we are in the mids of changing to 10.4 this is offcourse a showstopper…

could you have a look what could be the cause?
tia,
marc

Hi,

I think, I need your testcase for reproducing this issue.
you can send it to support@ for keeping privacy

Note: they recently released Delphi 10.4.1 - http://docwiki.embarcadero.com/RADStudio/Sydney/en/10.4_Sydney_-_Release_1 , so it may have a sense to upgrade 10.4. sp3 to it.

as usual there are issues with every release of delphi, the latest is no exception, that’s why we decided to stick to 10.4.0 sp3 for the moment
i understand that a testcase is the preferrable way, but that takes time which i don’t have at this point, that said, i’ll see what i can come up with
but if you in the mean time could have a look at how datmemo is handled in both versions? if there is no change between versions than it probably is a delphi problem not?


could this be the change that i’m facing now?

if they now default to null instead of empty then the variantowriter does not cope with the datmemo
i guess Null may be treated the same as empty?

changing the procedure as follows does solve the issue

    case VarType(aSourceVariant) of
      varEmpty, varNull:begin
          lSize := 0;
          aWriter.Write(lSize, SizeOf(lSize));
        end;

Hi,

according to their info, RSP-27730 was fixed 27/May/20, so Delphi 10.4 sp3 should have it.

cool. I wanted to suggest this workaround too

but that means that they’ve changed the way memo’s are handled right?
the same issue will exist in bin2?

Hi,

As I can see, Bin2 isn’t affected to this issue.

i’m gonna replace binmessage with bin2message
i don’t see any drawbacks using bin2message in combination with DA3
iirc bin2message was introduced while DA3 was still around?

tia,
marc

Hi,

Bin2 was developed as a replacement of Bin1
also it provides benefits like a performance boost in comparing with Bin1

yep that i know… i’m just trying to remember why i’m still using bin1 in 80% of all data access…
we even mimicked the reduced delta behaviour in case of bin1…