Skip to content

Commit f38dd51

Browse files
authored
Merge pull request wintersrd#65 from s7clarke10/feature/fix_singer_decimal
Supporting different SQL Server info schemas - Singer Decimal
2 parents 8028e65 + 83155f2 commit f38dd51

File tree

4 files changed

+8
-4
lines changed

4 files changed

+8
-4
lines changed

.bumpversion.cfg

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[bumpversion]
2-
current_version = 2.2.2
2+
current_version = 2.2.3
33
parse = (?P<major>\d+)
44
\.(?P<minor>\d+)
55
\.(?P<patch>\d+)

CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# tap-mssql 2.2.3 2024-02-26
2+
3+
* Bug Fix. Enhancing singer-decimal output for numeric data to correctly output the correct datatype - string and precision.
4+
15
# tap-mssql 2.2.1 2023-10-30
26

37
* Bug Fix. Removing test code which slipped into the release, and adjusting offending code with correct dynamic column name.

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "tap-mssql"
3-
version = "2.2.2"
3+
version = "2.2.3"
44
description = "A pipelinewise compatible tap for connecting Microsoft SQL Server"
55
authors = ["Rob Winters <[email protected]>"]
66
license = "GNU Affero"

tap_mssql/__init__.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -122,9 +122,9 @@ def schema_for_column(c, config):
122122

123123
elif data_type in DECIMAL_TYPES:
124124
if use_singer_decimal:
125-
result.type = ["null","number"]
125+
result.type = ["null","number","string"]
126126
result.format = "singer.decimal"
127-
result.additionalProperties = {"scale_precision": f"({c.character_maximum_length},{c.numeric_scale})"}
127+
result.additionalProperties = {"scale_precision": f"({c.character_maximum_length or c.numeric_precision},{c.numeric_scale})"}
128128
else:
129129
result.type = ["null", "number"]
130130
result.multipleOf = 10 ** (0 - c.numeric_scale)

0 commit comments

Comments
 (0)