Recent

Author Topic: RXDBgrid footer error  (Read 2455 times)

Igor Antić

  • Newbie
  • Posts: 4
RXDBgrid footer error
« on: April 25, 2016, 05:30:49 pm »
Dear,

Please, I need your help with package component named RXDBgrid version 2.8.3.183.

I use Windows 8.1 Professional operating system with Lazarus version 1.4.4 (see attached screenshot) and I noticed “strange condition” ?

Well,

I receive an error which consists in RXDBgrid when I try to load single row?

An error consists in the impossibility Rxdbgrid that if SQLQuery1 load single row, displays that row and at the same time show in the footer an aggregate function (SUM, AVG, MIN, MAX, COUNT, REC.No) If it is included in at least one of the columns.

Fields that are loaded into RXdbgrid the double type.


If the option is disabled, for the columns footer, for all fields, and footer is enabled at the level Rxdbgrid and SQLQuery1 load single row then Rxdbgrid displays the same one without amount in footer.


When I enable footer for any of column an error occurs if SQLQuery1 load single row.
If SQLQuery1 is empty or SQLQuery1 has more than one row everything works as it should. Component load row in the grid and display the footer.

I think I have a solution?


When I add to the unit rxdbgrid at row 4912 the following code:
if DHS.RecordCount> 1 then DHL.ActiveRecord: = 0;
instead of
DHL.ActiveRecord: = 0;

In this case, the basic process of footer formation with aggregate functions (SUM, AVG, MIN, MAX, COUNT, REC.No) , regardless of the number of rows loaded with SQLQuery1.

The only unknown scenario is that I do not know whether to cause additional consequences for other processes.

Please find enclosed the project1 database. We work with mysql and the schema name is aska_tmp.

 

TinyPortal © 2005-2018