Hardware FixRecommendedDevice not working? Your driver may be the problemCheck updates for common hardware issues.Fix DriversHalloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan Now×
FREEDOM251

Freedom251 › Blog › AI agents

Why 38.5% of an Analyst’s Questions Returned “No Records Found” in One Demo

By Freedom251 Team · · 4 min read

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

In one demo reported by Ashish Sinha, 5 of 13 questions for an analyst role—38.5%—were classified as unanswerable because their correct answers required tables that role could not read. A query against such a table could return an empty result under row-level security (RLS), making “no matching records” look much like “the matching rows exist, but you cannot see them.” This is a result from one schema and question set, not a general rate for analysts or text-to-SQL systems.

What the 38.5% figure measures

Sinha’s September 23, 2026 DEV Community post defines a question as unanswerable for a caller when its correct answer requires at least one table the caller is not permitted to read. The rate is the number of such questions divided by the total number tested. It is a structural measure based on role permissions and question-to-table labels; it does not require running a language model or executing SQL.

As an Amazon Associate I earn from qualifying purchases.

The reported result comes from one demo with a 42-object schema and 13 labelled questions per role. The author says the result depends on the schema, role model and question mix—not simply on which model is connected. The post does not establish independent replication or a production benchmark.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Role in the demo Unanswerable questions Reported rate
Analyst 5 of 13 38.5%
Finance 1 of 13 7.7%
HR 4 of 13 30.8%
CFO 0 of 13 0.0%

These are the author’s reported counts for the same demo, not expected rates for people with those job titles elsewhere. The question set and access rules determine what the fractions mean. Read Ashish Sinha’s DEV Community post.

#1 Best Overall
Mhfpl Nice Story Now Show Me The Data Black Gold A5 Spiral Notebook
  • Thoughtful Gift Choice: A gift for data analysts, researchers, scientists, and coworkers who like to back up their ideas with evidence. Suitable for birthdays, graduations, work anniversaries, office gift exchanges, or a thank-you gift for a colleague.
  • Optimal Size & Quality: Measuring 6.3" x 8" (A5), it features 160 pages of smooth 80gsm cream paper that protects your eyesight and enhances your writing experience.
  • Great Design: The double-wire spiral binding allows easy page flipping, while the sturdy 2mm thick black hard cover keeps your notes secure and intact.
  • Versatile Usage: Compact and portable, this notebook fits easily in bags, making it ideal for office, school, home, or travel.
  • Creative Freedom: Blank inner pages provide endless possibilities for writing, sketching, and expressing your creativity.

Why a restricted table can look like missing data

In the failure path Sinha describes, the agent receives a broad schema, chooses a table the caller cannot access, and sends a query. The database remains responsible for permissions: grants or RLS can filter out rows, leaving the application with an empty result. If the application sees only that empty list, it may report “no records found” without distinguishing between two different explanations:

  • No rows matched the query.
  • Matching rows exist, but the caller is not allowed to see them.

An empty response alone therefore does not explain whether the data is absent or access-filtered. The demo illustrates a way that mismatch can occur; it does not show how often it occurs in production systems.

Rank #2
Hardcover Lined Notebook Journal for Writing, 320 Pages Leather Thick College Ruled Notebook Journal with 100GSM Paper, A5 (5.7'' X 8.4'') Daily Journal for Women Men Work Organization, Black
  • 【320 Pages Hardcover Thick Notebook】This faux leather journal notebook A5 (5.7'' X 8.4'') size lined notebook journal has a total of 320 pages (including 6 catalog pages), 7mm space classic college ruled notebook, providing you with plenty of writing space.
  • 【100GSM Premium Paper】The notebook journal is made of 100gsm ivory thick paper, the paper is smooth, the writing is smooth, and the ink will not bleed, suitable for most pens. Our leather notebooks feature a 180° lay-flat design for easy writing, easier reading and more efficient note taking.
  • 【Notebook Features】The journal has 6 Contents Pages to log more entries, No more worrying about not having enough index pages; 3 Exquisite ribbon bookmarks to help you find content faster; 1 Elastic closure strap to keep the notebook closed; 1 Double-stitched elastic pen holder ring, can hold most pens; 1 Inner pocket for appointment cards, notes, receipts and more.
  • 【Great Use】Thick hardcover notebook journal is ideal for office, school and home use, and is a great gift choice for women, men, business executives, college, students and people in many other fields. It can be used as personal writing journal, daily journal, to do list notebook, business notebooks, work notebooks, college ruled notebook, note taking journal and more.
  • 【After-sales Service】Each leather journal notebook comes with 1 gift of multicolor index tabs stickers for papers classifying and marking. If you receive the notebook is damaged or have any problems in the process, please contact us, we will be the first time for you to solve all your problems!

How to measure structural unanswerability

With labelled questions

The stronger method in the post starts with a gold set that identifies which tables each question needs, alongside the tables each caller may read. For every question, compare its required tables with that caller’s denied tables. Count a question as unanswerable if the two sets intersect, then divide that count by the number of questions tested.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Sinha notes that datasets such as Spider and BIRD provide the kind of question-to-table labels this method needs. The post does not report applying the measurement to either dataset. A measured rate is only as representative as the selected questions, role definitions and table labels.

Without labelled questions

When gold labels are unavailable, the post proposes generating probe questions from each restricted table’s name, hint or description, then checking whether an unscoped schema-selection step retrieves that table. This can indicate whether the table is reachable using its own vocabulary, but it is not a substitute for a rate based on representative, labelled questions. A negative result only shows that the table was not reached by those probes; it does not prove that real questions cannot lead to it.

The author also describes an early bug in which principal=None was treated as a caller with no permissions rather than as an unscoped principal. That caused the probe to report zero of five restricted tables as reachable. Sinha says the tool now has a named regression test and paired tests intended to verify that the metric can move. These are the author’s account of the implementation and tests, not an independent audit.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Why scope the schema before generating SQL?

The proposed intervention is to make schema selection caller-aware: provide the agent only the tables that caller may read, and detect when a question needs a table that is missing before SQL generation. That can surface an access-versus-availability mismatch earlier than relying on an empty query result to explain itself.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

In Sinha’s demo, a full-schema path detected 0 of 10 blocked caller-question pairs before SQL, while a caller-scoped path detected 10 of 10. Those counts describe the author’s demo and its structural setup; they are not a comparison of model quality and do not predict results for a production catalogue.

Approach When caller access shapes the schema What the result can establish
Full schema, then database filtering After the agent has seen the schema and selected tables for a query In the reported demo, the path did not detect blocked pairs before SQL. Database permissions still determine which rows are returned.
Caller-scoped schema before generation Before the agent selects tables and generates SQL In the reported demo, the path detected blocked pairs before SQL. The result depends on the demo’s schema, roles and questions.
Schema-derived vocabulary probes During a probe of table names, hints or descriptions Whether those probes can reach restricted tables; not a general unanswerability rate.

Schema scoping is not an authorization control

Schema scoping is an earlier check and a way to improve what the agent knows about the caller’s accessible data. It does not replace database grants or RLS. Those controls must continue to enforce access even if an application supplies a scoped schema: schema information guides selection, while the database protects the data.

The demo supports a specific takeaway: inaccessible tables can contribute to empty-result ambiguity, and caller-aware schema selection can expose that mismatch in the described setup. It does not establish a general 38.5% failure rate, a model score, or a security guarantee.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

AI agentsdata securitydatabase accessrow-level securityText to SQL

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Recommended PC Tool
Recommended PC Tool
Crashes, No Sound, or Screen Glitches?Free driver scan
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.