You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Follow-up from the #43 code review. The primary identifier-quoting fix (#43) makes the schema tree and lineage-graph vectors emit valid SQL for names like target_all.part-00000-…-c000.snappy.parquet``. Two deeper paths remain shallow and are tracked here.
completions.js now quotes the candidate insert value, but completionContext (same file) still detects the typed word and the qualified parent using [A-Za-z0-9_] only:
Mid-word splice: typing part-00 leaves the caret in a word that starts after the - (word = 00); accepting splices the quoted name into the middle → part-`` part-…parquet` `` — invalid. (Pre-existing for dashed names; quoting doesn't fix it.)
Lost qualified completion: after a backticked parent `my-db`., the char before the . is a backtick, so parent='' and the table's column dropdown never appears.
A real fix teaches completionContext to recognize a backtick-quoted run as a single word/parent, and to match candidates whose label contains non-word chars.
2. qualify() is a dot-heuristic for MV-target / EXPLAIN-AST names
schema-graph.jsqualify(db, name) decides "already db-qualified?" by name.includes('.'). For a dotted table name this misfires:
parseMvTarget won't match a backticked TO target → no writes edge.
parseAstTables tokens for dotted/backticked names are treated as already-qualified, so byId.has(sid) (keyed on raw db.name) misses → feeds/reads edges dropped.
So whole-DB/table lineage silently omits edges for exactly the dotted (parquet-import) tables that motivated #43. A depth-correct fix carries db separately out of parseMvTarget/parseAstTables (and strips backticks) instead of guessing from a dot.
3. (Optional) No chokepoint / guard for identifier quoting
Quoting is applied at ~8 call sites with no single constructor and no test/lint that flags a future raw '… FROM ' + name. Consider a guard test or a structural chokepoint so a new identifier→SQL site can't silently reintroduce the bug.
Context: #43 (the quoting fix), #41 (the lineage graph).
Activity
Merge pull request #45 from Altinity/feat/issue-44-dotted-names