Support paging in FireDAC !!!

This is the forum for miscellaneous technical/programming questions.

Moderator: 2ffat

Support paging in FireDAC !!!

Postby Ahmed Sayed » Thu Jan 31, 2019 9:09 am

I am trying to support paging in FireDAC like websites do. Let the user choose how many records to show and display the pages count as it should be. But i can't achieve this with FireDAC on REST Server (RAD Server) I mean how can I get first the total count of records although I have my TFDQuery Fetching Mode Set to OnDemand or Manual not All records. When check the RecordsCount property I always get only the fetched records not the whole query records. I though that FireDAC executes a "Select count(*) From (mysql statement here)" before executing the original sql to get the actual data.

So my questions are how can I know the total records count while I use on demand or manual fetching in FireDAC? or How can get the sql statement after FireDAC has inserted parameters values to execute the
"Select count(*) From (mysql statement here)" query my self on the resulting sql statement?

Thanks in advance
Any help will be really appreciated
Ahmed Sayed
Active Poster
Active Poster
 
Posts: 24
Joined: Thu Nov 08, 2018 4:12 pm

Return to Technical

Who is online

Users browsing this forum: No registered users and 16 guests

cron