Skip to content

fix(sql): SQL-grid Save parity with Table Browser (schema error, rowid, columnMeta) #868

Description

@ZhuchkaTriplesix

Summary

SQL result-grid Save still lags Table Browser after #772 / #774 / #792.

  1. Schema load failuregetTableSchema is catch (_) { pks = []; } in PG/MySQL/SQLite SQL workspaces. Save stays off; status is still N row(s). — indistinguishable from a healthy grid. Table Browser now shows “schema unavailable”.
  2. SQLite implicit rowid — SQL SELECT * does not project rowid and uses declared PKs only. Table Browser edits CREATE TABLE t (name TEXT) via rowid; SQL-grid cannot Save.
  3. columnMeta omittedgenerateMutationPlan gets columnDataTypes but not columnMeta, so generated / AUTO_INCREMENT INSERT columns are not omitted (Table Browser does).

Scope

  • Reuse loadTableViewSchema (or equivalent) and surface schema errors in the SQL status line.
  • Apply sqliteTableBrowserPrimaryKeys + project rowid when needed (or document that SQL-grid Save requires rowid in the SELECT).
  • Pass columnMetaFromSchema into SQL-grid mutation plans.

Out of scope

  • Execute discarding dirty edits (separate issue).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingdata-gridInteractive data grid, cell editor, filtering, groupingserror-handlingTheme parser epic label: error-handlingsqliteSQLite database driver and workspace

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions