Skip to content
This repository was archived by the owner on May 17, 2024. It is now read-only.

Commit 598d98c

Browse files
author
Sergey Vasilyev
committed
Normalise all numbers, not only fractional in MS SQL
1 parent 57b889d commit 598d98c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

data_diff/databases/mssql.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
from data_diff.databases.base import Mixin_Schema
1717
from data_diff.abcs.database_types import (
1818
JSON,
19+
NumericType,
1920
Timestamp,
2021
TimestampTZ,
2122
DbPath,
@@ -50,7 +51,7 @@ def normalize_timestamp(self, value: str, coltype: TemporalType) -> str:
5051

5152
return formatted_value
5253

53-
def normalize_number(self, value: str, coltype: FractionalType) -> str:
54+
def normalize_number(self, value: str, coltype: NumericType) -> str:
5455
if coltype.precision == 0:
5556
return f"CAST(FLOOR({value}) AS VARCHAR)"
5657

0 commit comments

Comments
 (0)