Home > Back-end >  How to use Delphi to form data statistics
How to use Delphi to form data statistics

Time:09-20

Query statistics on table form for operation by using Delphi controls, when at the end of the query operation, want to use the label control to statistical number of queries to the form of late, how to programming?

CodePudding user response:

Stick out of the field, and statistical requirements, all staff for you,

CodePudding user response:

Using a two SQL, used to display the form, one for statistical number of late,

CodePudding user response:

A select number of late from the table where conditions
Want to see what is your specific requirements, or your specific requirements to stick out

CodePudding user response:


Can not directly use Sql processing, such as the Sum of functions, or cyclic statistics can also be found to client

CodePudding user response:

The table set up by using the database table is as follows:

In Delphi for page layout, need all information query class for the students of class 141, and will be late for class number 141, leave number, number of truancy statistics respectively, shown on the label
[
Now the problem is don't know how to write code can achieve the desired effect?

CodePudding user response:

Processing data in the database directly, using the Sum function Sum, then displayed on the label
Select the name, the sum (chi) as TotalLate from table group by name. This is late by name and number, namely the number of late for everyone,
  • Related