[coverage] Conformance findings: PARAMQUERY-021
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 55/100
- Issue-Typ
- Bug
- Klarheit
- Größtenteils klar
- Aktivitätsstatus
- Ruhig
- Tech-Stack
- node.js, sql, typescript
Rechercherichtung
Das fehlschlagende xfail trägt den Namen “DECIMAL target — a scale-less DECIMAL declaration must not truncate the value’s fractional digits” und wird unter tests/ in coverage PR 1179 referenziert. Beginne damit, den Thrift-Parameter-Binding-Pfad für DBSQLParameterType.DECIMAL zu finden und den Coverage-Test gegen den Connector auszuführen. Erledigt ist es, wenn deklarierte, skalierungslose und zu niedrig deklarierte DECIMAL-Ziele jede Nachkommastelle ohne Abschneiden bewahren.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Summary
Surfaced by the multi-language coverage fan-out while conformance-testing these SPEC-IDs against databricks/databricks-sql-nodejs. Each finding is committed as an expected-failure (xfail) test in the coverage PR — the test asserts the CORRECT (post-fix) behavior and stays red until THIS driver (databricks/databricks-sql-nodejs) is fixed, then flips green as a tripwire.
Findings
- PARAMQUERY-021 [thrift]: Thrift path truncates a scale-less DECIMAL target: '123.45' bound as DBSQLParameterType.DECIMAL rides with scale 0, so
SELECT :vreturns 123, destroying the fractional digits- failing test:
DECIMAL target — a scale-less DECIMAL declaration must not truncate the value’s fractional digits [xfail: thrift](see the coverage PR diff undertests/)
- failing test:
- PARAMQUERY-021: Thrift path truncates a scale-less DECIMAL target: '123.45' bound as DBSQLParameterType.DECIMAL is sent with scale 0, so
SELECT :vreturns 123 instead of 123.45, silently destroying the value's fractional digits (the SEA/kernel path returns 123.45 correctly)
Reproduce & Expected
PARAMQUERY-021 — Verify that declaring a DECIMAL/NUMERIC target type for a bound parameter never silently drops fractional digits.
Reproduce:
SELECT ? AS v
SELECT ? AS v
SELECT ? AS v
Expected (per the shared spec):
- All three binds prepare and execute successfully.
- (a) The declared DECIMAL(10,2) accommodates the value, so the parameter rides as that decimal type and the value compares numerically equal to 123.45 with both fractional digits intact.
- (b) THE CORE GUARANTEE: with no declared scale, the value is still 123.45 -- NOT 123. Assert the value, not the reported column type: a conforming driver may legitimately deliver this as a decimal the server inferred from the literal OR as the lossless text/string form, so the type is implementation latitude while the VALUE is the contract.
- (c) The value's own scale (4) is authoritative over the under-declared target scale (2): all four fractional digits survive. A result of 123.45 (or 123) is a truncation violation.
Context
- The behavior was first fixed in a DIFFERENT driver — reference PR: https://github.com/databricks/databricks-odbc/pull/167 — which seeded the shared language-neutral spec. This issue tracks the same conformance gap in databricks/databricks-sql-nodejs; the reference PR is for cross-referencing the intended behavior, NOT a change to this repo.
- Coverage PR carrying the reproducing xfail test(s): https://github.com/databricks/databricks-driver-test/pull/1179
- Vorherrschende Sprache
- TypeScript
- Sterne
- 37
- Forks
- 51
- Ø Merge
- 5 Std. 56 Min.
- Gemergte PRs (30 T.)
- 9
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Keine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus databricks/databricks-sql-nodejs
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
databricks/databricks-sql-nodejs#526 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
databricks/databricks-sql-nodejs#503 ·
Maintainer antworten meist innerhalb von 1 Tag
-
engineer-bot
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 64/100
databricks/databricks-sql-nodejs#274 · 1 Kommentar · 1 Reaktion ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 68/100
databricks/databricks-sql-nodejs#525 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 35/100
databricks/databricks-sql-nodejs#524 ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in databricks/databricks-sql-nodejs
Ähnliche Issues
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 72/100
betagouv/mon-entreprise#4699 ·
Maintainer antworten meist innerhalb von 3 Tagen
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
jaegertracing/jaeger-ui#4547 · 3 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
ai-driven-qa
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 84/100
linagora/twake-calendar-frontend#1467 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
need4deed-org/sdk#267 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 84/100
auth0/universal-login#414 ·
Maintainer antworten meist innerhalb von 1 Tag