#1 2021-01-06 15:31:55

b-57
Member
Registered: 2020-12-10
Posts: 4

Sample-16 : execute block Firebird

Hi All,
I modified sample-16, and add ZeosLib for connecting firebird db,

On sample-16 Client , this query is working

    select '%' ATEXT from RDB$DATABASE
    union 
    select 'B' ATEXT from RDB$DATABASE

but not returning any rows for this query :

execute block RETURNS( ATEXT TVARCHAR15 )
as 
begin
  for
   select x.* from
   (
    select '%' ATEXT from RDB$DATABASE
    union 
    select 'B' ATEXT from RDB$DATABASE
   ) x  into :ATEXT
  do begin
      suspend;
   end  
end

Is EXECUTE BLOCK  not supported  ?

Offline

#2 2021-01-06 16:32:08

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,659
Website

Re: Sample-16 : execute block Firebird

It is used for batch writing with no problem.

Perhaps it is supporting EXECUTE BLOCK for reading.

Could you debug a bit more on your side to see what's wrong?

Offline

#3 2021-01-07 06:54:36

b-57
Member
Registered: 2020-12-10
Posts: 4

Re: Sample-16 : execute block Firebird

Thank Ab for reply

After looking client code

        if isSelect(pointer(SQL)) then begin
        fTableJSON := fService.Execute(SQL,True,False);
        ... draw to grid 

        end else
          fService.Execute(SQL,False,False);

after delete/comment out  isSelect function
now 'Execute Block Returns' can run.

Offline

Board footer

Powered by FluxBB