DA for firemonkey Android

Hi,

My environment is 10.3.1, DA : [-9.6.113.1419], Android SDK 26.2

I build a FMX application wizard for server an client.

It only have 2 function open table without dynamic where and open table with dynamic where.
When run in a android

  1. open table without dynamic where --> run correctly
  2. open table with dynamic where --> show exception ( DOMelement is NIL).

IN the attached picture: Open , Number of record 2 << from open table without dynamic where
Exception message is from open table with dynamic where

I attached the Testing project for reference
please advise how to solve.

actually before this error also found in version 9.5.111.1399 but only occur in client direct select sql to server to get data.

mobileConnectDB.zip (209.6 KB)
20190509125759

Hi,

can you test this issue with 9.7 beta? we have already fixed this or similar issue after 9.6 RTM

will test later and let you know

we tested RemObjects Data Abstract for Delphi, Server Edition - 9.7.115.1441 this version
The result is same.

Which version I should Try?

weird, I’ll retest your testcase

Thanks wait for your reply

yep, I can reproduce this issue.
by some reasons, fDocument.documentElement is nil.
will see what is wrong with Xml.omnixmldom

Thanks, logged as bugs://82801

bugs://82801 got closed with status fixed.

pls update uRONextGenXMLImpl.pas as

function TRONextGenXMLNode.GetXML: UnicodeString;
..
{$IFDEF DELPHIXE7UP}
  Result := TrimRight(TrimLeft((fNode as IDOMNodeEx).xml)); //changed
procedure TRONextGenXMLDocument.New(aDocumentName : UnicodeString = ''; anEncoding : TXMLEncoding = xeUTF8; aNameSpace: UnicodeString='');
..
    fDocument := OmniXML4Factory.DOMImplementation.createDocument(aNameSpace, aDocumentName, nil);
    fDocument.appendChild(fDocument.createElementNS(aNameSpace, aDocumentName)); //added

Thanks it solved. But I hit another issue on it.

whenever I open a datatable with a Float field. it show bus error see attached .
Also when I open datatable with datetime field it can open but locate a datetime field it also with same bus error.

Error_20190621113529

I attached a sample project and DB for reference. Please comment.

mobileConnectDB(1).zip (227.9 KB)

I can’t reproduce this error:

I’ve used Delphi 10.2.3 & Android 5.1.1 (API=22)

My Environment is:
delphi Version 10.3, Android API = 26.2 ( 32bit)

Any Suggestion?

can you show callstack for this error, pls?

see if can help

try to add empty OnReadFieldValue event:

procedure TClientDataModule.DataStreamerReadFieldValue(const aField: TDAField;
  var Value: Variant);
begin
//
end;

will it solve this issue?

This can solve open table but cant solve locate issue.

But this is will slow down the open process. Can you explain why bus error come?
any suggestion on solve it with good speed?

I’ve tried to reproduce this but it was unsuccessfully - Delphi IDE shows Performing Streamed Install error when it tried to upload project to emulator with Android API = 25-29.

From your callstack and errors, it may dislike PDouble(buf1)^ in

datFloat: PDouble(buf1)^ := Bin2_ReadDoubleFromStream(Data);

can you confirm this in debugging, pls?

Yes you are correct this is the problem line

as I see, they have changed

procedure TFloatField.SetAsFloat(Value: Double);
begin
  if FCheckRange and ((Value < FMinValue) or (Value > FMaxValue)) then
    RangeError(Value, FMinValue, FMaxValue);
  SetData(@Value);
end;

with

procedure TFloatField.SetAsFloat(Value: Double);
begin
  if FCheckRange and ((Value < FMinValue) or (Value > FMaxValue)) then
    RangeError(Value, FMinValue, FMaxValue);
  if FIOBuffer <> nil then
    TDBBitConverter.UnsafeFrom<Double>(Value, FIOBuffer);
  SetData(FIOBuffer);
end;

looks like we should also use TDBBitConverter methods.