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
Copy file name to clipboardExpand all lines: docs/machine-learning/known-issues-for-sql-server-machine-learning-services.md
+9-1Lines changed: 9 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,7 +3,7 @@ title: Known issues for Python and R
3
3
description: This article describes known problems or limitations with the Python and R components that are provided in SQL Server Machine Learning Services and SQL Server 2016 R Services.
4
4
ms.prod: sql
5
5
ms.technology: machine-learning-services
6
-
ms.date: 07/07/2020
6
+
ms.date: 07/14/2020
7
7
ms.topic: troubleshooting
8
8
author: dphansen
9
9
ms.author: davidph
@@ -528,6 +528,14 @@ SQL Server 2019 contains a regression that effects R scripts that use parallel e
528
528
529
529
**Applies to:** SQL Server 2019.
530
530
531
+
### 23. Precision loss for money/numeric/decimal/bigint data types
532
+
533
+
Executing an R script with `sp_execute_external_scripts` allows money, numeric, decimal, and bigint data types as input data. However, because they are converted to float internally, they suffer a precision loss with values that are very high or have decimal point values.
534
+
535
+
+**money**: Sometimes cent values would be imprecise and a warning would be issued: *Warning: unable to precisely represent cents values*.
536
+
+**numeric/decimal**: `sp_execute_external_scripts` with an R script does not support the full range of those data types and would alter the last few decimal digits especially those with fraction.
537
+
+**bigint**: R only support up to 53-bit integers and then it will start to have precision loss.
538
+
531
539
## Python script execution issues
532
540
533
541
This section contains known issues that are specific to running Python on SQL Server, as well as issues that are related to the Python packages published by Microsoft, including [revoscalepy](https://docs.microsoft.com/r-server/python-reference/revoscalepy/revoscalepy-package) and [microsoftml](https://docs.microsoft.com/r-server/python-reference/microsoftml/microsoftml-package).
Copy file name to clipboardExpand all lines: docs/machine-learning/r/r-libraries-and-data-types.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,17 +35,17 @@ The following table shows the changes in data types and values when data from [!
35
35
36
36
|SQL type|R class|RESULT SET type|Comments|
37
37
|-|-|-|-|
38
-
|**bigint**|`numeric`|**float**||
38
+
|**bigint**|`numeric`|**float**|Executing an R script with `sp_execute_external_scripts` allows bigint data type as input data. However, because they are converted to float internally, it suffers a precision loss with values that are very high or have decimal point values. R only support up to 53-bit integers and then it will start to have precision loss.|
39
39
|**binary(n)**<br /><br /> n <= 8000|`raw`|**varbinary(max)**|Only allowed as input parameter and output|
40
40
|**bit**|`logical`|**bit**||
41
41
|**char(n)**<br /><br /> n <= 8000|`factor`|**varchar(max)**||
42
42
|**datetime**|`POSIXct`|**datetime**|Represented as GMT|
43
43
|**date**|`POSIXct`|**datetime**|Represented as GMT|
44
-
|**decimal(p,s)**|`numeric`|**float**||
44
+
|**decimal(p,s)**|`numeric`|**float**|Executing an R script with `sp_execute_external_scripts` allows decimal data type as input data. However, because they are converted to float internally, it suffers a precision loss with values that are very high or have decimal point values. `sp_execute_external_scripts` with an R script does not support the full range of the data type and would alter the last few decimal digits especially those with fraction.|
45
45
|**float**|`numeric`|**float**||
46
46
|**int**|`integer`|**int**||
47
-
|**money**|`numeric`|**float**||
48
-
|**numeric(p,s)**|`numeric`|**float**||
47
+
|**money**|`numeric`|**float**|Executing an R script with `sp_execute_external_scripts` allows money data type as input data. However, because they are converted to float internally, it suffers a precision loss with values that are very high or have decimal point values. Sometimes cent values would be imprecise and a warning would be issued: *Warning: unable to precisely represent cents values*. |
48
+
|**numeric(p,s)**|`numeric`|**float**|Executing an R script with `sp_execute_external_scripts` allows numeric data type as input data. However, because they are converted to float internally, it suffers a precision loss with values that are very high or have decimal point values. `sp_execute_external_scripts` with an R script does not support the full range of the data type and would alter the last few decimal digits especially those with fraction.|
49
49
|**real**|`numeric`|**float**||
50
50
|**smalldatetime**|`POSIXct`|**datetime**|Represented as GMT|
0 commit comments