Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[coverage] Conformance findings: PARAMQUERY-021

Open
#490 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
55/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Domain
backend, databases

Research direction

The failing xfail is named “DECIMAL target — a scale-less DECIMAL declaration must not truncate the value’s fractional digits” and is referenced under tests/ in coverage PR 1179. Start by locating the Thrift parameter-binding path for DBSQLParameterType.DECIMAL and run the coverage test against the connector. Done means declared, scale-less, and under-declared DECIMAL targets preserve every fractional digit without truncation.

Written by the indexing model from the issue text.

Description

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 :v returns 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 under tests/)
  • PARAMQUERY-021: Thrift path truncates a scale-less DECIMAL target: '123.45' bound as DBSQLParameterType.DECIMAL is sent with scale 0, so SELECT :v returns 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

Dominant language
TypeScript
Stars
36
Forks
50
Avg merge
13h 46m
Merged PRs (30d)
9

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from databricks/databricks-sql-nodejs

All issues in databricks/databricks-sql-nodejs

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.