How to Get a Google Sheets QUERY from Plain English

Sheets QUERY prompts fail by inventing columns. You asked who is overdue. The formula filters Status, Due, and Owner. Your sheet has Task and When. The formula errors, or worse, someone adds the missing columns and now you have two truths. The job is a QUERY that matches stated headers only, with gaps when the question needs a field you do not have.
The matching generator is the Google Sheets QUERY from a Plain-English Question prompt. Browse related cards in the PromptDig library (Browse more prompts). When a filled run survives, share the version you actually use (Share a prompt).
Headers are the schema. The question is not a request to add columns.
Paste the exact header row. Case and spelling matter. Workflow is what the sheet is for. The plain-English question is Pain plus the ask: "which rows are still open this week." Cadence is how often the formula should be reread. Do not automate: volatile whole-column pulls if you said no, or scripts if you want a formula only.
Tools: Google Sheets. Version-lock if you named a locale (comma vs semicolon arguments). If unnamed, write unknown and pick one locale, labeled.
QUERY text that can be pasted, plus a sample row that is not PII
The artifact is the formula: QUERY(range, "select ... where ...", 1) using only named headers. If the sheet uses A1 without a header map, say so and refer to column letters you were given. Do not invent Col10.
If the question needs a column that is not in Fields, do not add it inside QUERY. Write: cannot answer from current headers; missing X. Offer a second formula only after listing the new header as a Gap the human must add.
Sample row: clearly fake values that match types (dates as dates, numbers as numbers). No real emails. Explain GROUP BY and LABEL only if the question asked for a summary.
Maintenance: freeze header, do not insert columns left of the range without editing the formula, watch locale dates. If you use a named range, name it from Inputs, not a cute DataDump2026.
Gaps, locale, and the questions QUERY cannot legally guess
Gaps: missing unique ID, mixed date formats, merged cells, header typos, FILTER vs QUERY choice. If merged cells exist, say QUERY will break; unmerge first.
Do not emit IMPORTRANGE to a URL you were not given. Do not emit Apps Script if DoNot said formula only. De-identify any pasted rows.
This is not a full data-model redesign. If the sheet is the wrong shape, say so in Gaps. Then still give the best QUERY on the headers you have, or refuse with the missing field named.
A worked pass: missing Owner means no Owner filter
Headers: Task, When, Status. Question: who is overdue. There is no Owner and no Due column, only When. The card should say it cannot answer "who" without Owner, and it can list rows where When is before today and Status is not done, if When is a date. Formula uses those headers only.
If When is mixed text, Gaps say so. Do not emit a QUERY that invents a Due column. Do not IMPORTRANGE a workbook URL you did not paste.
Locale: if you did not name it, label the argument separator you chose. Maintenance: do not insert a column inside the range. Sample row: Task "File QBR notes," When a fake date, Status "open." No personal emails. The honest answer is often a formula plus a missing-header line, not a cleverer QUERY.
Fill the card, then run
Paste the header row and the question in the same words you would ask a colleague. If a column does not exist, do not ask the model to pretend it does.
Workflow / role: [Workflow]
Tools (Sheets locale if known): [Tools]
Fields I actually have (header row): [Fields]
Cadence: [Cadence]
Pain today / the question: [Pain]
Do not automate: [DoNot]
QUERY is picky on purpose. When a run returns "missing Owner, cannot filter" instead of a invented column, share that filled card. That is the formula you can paste without quietly changing the sheet.