How to Query Records with Missing Reports Before the Current Month
Question details
The user needs to find records that are missing monthly reports for completed months, without including future uncompleted months.

- Product
- Database Management
- Device & OS
- not provided
- Scenario
- Tracking missing monthly submissions across multiple years in a relational database.
- Observed behavior
- The current setup uses twelve individual monthly checkbox columns, which scales poorly across multiple years and makes querying for missing past reports overly difficult.
Before modifying your database structure, ensure you have a complete backup of your tables and are prepared to migrate your existing checkbox data into a new relational table.
Normalize Your Database Structure
Replace the monthly checkbox columns with a normalized child table that logs each received report individually.
Using a separate column for each month creates significant scalability issues when your data spans across multiple years. A relational database functions best when each received report is stored as an individual row in a child table, rather than relying on Boolean checkbox fields.
Create a new table (e.g., tblReceivedReports) containing fields for RecReportID, ReceivedDate, ReportID, and ParentID.
If you are tracking multiple types of reports, create a separate lookup table containing ReportID and ReportName to organize the entities properly.
Transfer your current monthly checkbox data into the new child table. In this new structure, compliance is simply determined by whether a row exists for that specific month and entity.

Query Missing Reports Using NOT EXISTS or NOT IN
Use a correlated subquery alongside a calendar table to identify entities missing reports for previous months.
Analyze Missing Data Easily with WPS Office
If building complex relational database queries in Microsoft Access is too complicated, WPS Spreadsheets offers a free, lightweight, and easy-to-use alternative. You can track monthly reports seamlessly using intuitive tables, VLOOKUPs, and PivotTables while maintaining full compatibility with Microsoft Office formats.
- 1. Download WPS Office: Visit the official WPS website and download the free WPS Office suite to your computer.
- 2. Import your tracking data: Export your current tracking database to an Excel format and open it directly in WPS Spreadsheets.
- 3. Analyze missing reports instantly: Use conditional formatting, VLOOKUP, or PivotTables to instantly highlight records that are missing data for prior months.

Frequently Asked Questions
Why shouldn't I use a column for every month in my database?
Using a distinct column for every month violates database normalization principles. It requires constantly modifying the table structure as new years are added, and it makes writing queries to analyze missing data across multiple years highly complex and inefficient.
What is a correlated subquery?
A correlated subquery is a query nested inside another query that uses values from the outer query. In this scenario, it evaluates whether a corresponding report record is absent for each specific entity and past month being checked by the outer query.
How do I exclude future uncompleted months in my query?
You can exclude future months by adding a WHERE clause condition that compares the target month and year of the report against the current system date, ensuring that only periods strictly less than the current date are included in your results.




