KPI Values Not Displaying on Dashboard Cards Despite Data Exists in Source Table (AppSheet)

Dear AppSheet Community/Experts,

I am facing an issue with displaying my KPI values correctly on the dashboard view of my application. Although the data is successfully imported and the calculation logic is defined, the KPI cards on the dashboard consistently show a value of ‘0’ or appear blank where the actual number should be.

My goal is to show the calculated value for each specific KPI (e.g., Absent Count, Absenteeism Rate, etc.) on its corresponding card.

I suspect the issue might be related to how the KPI_Value column is used across the different rows in the KPI_List table, as each row represents a different KPI.

Here are the details and attached screenshots:

  1. Image 1 (image_7080ba.png): The Source Data Table (KPI_List)

    • This image shows the data source where the column KPI_Value [Number] is currently showing ‘0’ for most entries, even though my formulas are intended to calculate non-zero values.
  2. Image 2 (image_708137.png): The Dashboard View

    • This image shows the Dashboard where the cards are defined (e.g., “Absent Count,” “Absenteeism Rate (YTD)”). The value placeholder on these cards is either blank or showing ‘0’.

My setup details:

  • Table: KPI_List

  • Column: KPI_Value [Number] (This is where the calculated value should appear).

  • Current App Formula Example (for calculating Absenteeism Rate):

    (
    COUNT(SELECT(Reporting[Code], AND([Statut] = "Absent", MONTH([Starting_Date]) = ANY(SELECT(Settings[MonthNumber], [SelectedMonth] = TRUE)), YEAR([Starting_Date]) = YEAR(TODAY()))))
    /
    COUNT(SELECT(Reporting[Code], AND(MONTH([Starting_Date]) = ANY(SELECT(Settings[MonthNumber], [SelectedMonth] = TRUE)), YEAR([Starting_Date]) = YEAR(TODAY()))))
    ) * 100
    
    

    (Note: I understand that this specific formula needs to be wrapped in a SWITCH() statement to apply the correct calculation based on the [KPI_Name] row, but even when applying simpler formulas, the dashboard displays ‘0’.)

My Question is:

  • How can I ensure that the correct calculated value is dynamically fed from the KPI_List row to the specific card on my AppSheet Dashboard?

  • Should I be using a Virtual Column instead of the actual KPI_Value column to hold the SWITCH() formula?

Any guidance on the correct structure for the KPI_Value column logic in a multi-KPI data source would be highly appreciated.

Thank you for your time and help!


1 Like

Hey Abbas.

What you might try is to restructure how you’re storing your data:

  • Right now you’ve got 1 record per KPI

Maybe instead switch your thinking to having each record represent a DATE.

  • This is a common strategy employed by app builders
  • It allows you to “roll up” the data from a date into a record
  • You can then do that over time, and see how numbers have changed easily

How?

  1. Restructure your table so that you’ve got a column for each KPI you want to store; also include anything else important, like the date, maybe a list of IDs or a count of something… anything you might need for long-term analysis later
  2. Create an automation that runs on a schedule, that creates a record in the Daily_KPI table