Skip to content

Infer schemas for #table expressions - #285

Merged
Alex Vallone (amv146) merged 6 commits into
masterfrom
alexvallone/table-column-inference
Aug 24, 2026
Merged

Infer schemas for #table expressions#285
Alex Vallone (amv146) merged 6 commits into
masterfrom
alexvallone/table-column-inference

Conversation

@amv146

@amv146 Alex Vallone (amv146) commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Summary

  • recognize #table intrinsically without requiring library metadata
  • infer a DefinedTable schema from literal column-name lists
  • preserve explicit type table [...] schemas
  • enable field autocomplete from the inferred schema

Stack

  1. This PR: column/schema introspection
  2. Infer exact rows for #table expressions #286: exact row introspection

The row follow-up also depends on microsoft/powerquery-parser#411.

Validation

  • npm run build
  • npm run lint
  • npm test -- --grep "#table" (7 passing)
  • full suite (737 passing)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 9839e176-efce-4a70-811b-7e2668cdb7f3
alexvallone and others added 3 commits August 18, 2026 14:36
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 9839e176-efce-4a70-811b-7e2668cdb7f3
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 946bd35e-0c84-49f0-90ff-a15d522d34f8
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 946bd35e-0c84-49f0-90ff-a15d522d34f8
return Type.TableInstance;
}

const fieldName: string = TextUtils.unescape(element.literal.slice(1, -1));

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I forget if we have to worry about quoted identifiers?

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 946bd35e-0c84-49f0-90ff-a15d522d34f8
@amv146
Alex Vallone (amv146) merged commit 5de4b71 into master Aug 24, 2026
5 checks passed
@amv146
Alex Vallone (amv146) deleted the alexvallone/table-column-inference branch August 24, 2026 18:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants