为什么 Azure 数据工厂使用 ADF COPY 将我的 ORACLE 数字 (10,0) 存储到 PARQUET 十进制 (38,10)?

Why does Azure Data Factory store my ORACLE number(10,0) to PARQUET decimal(38,10) using ADF COPY?

当我在 Oracle Developer 中打开数据库时,MWD_ID 的数据类型是 NUMBER(10,0)

当我检查 sys.all_tab_columns 列时,data_length 是 22,精度是 10

我使用本机 oracle 链接服务连接到 Oracle 数据库。这些语句是根据我要导出的所有表中的列表生成的。以 Oracle Query 语句为源的示例。水槽是镶木地板文件。无法映射某些列来强制转换。

当我加载 parquet 文件并描述数据集时,格式已更改为 decimal(38,18)

The NUMBER datatype in Oracle stores fixed and floating-point numbers. Numbers of virtually any magnitude can be stored and are guaranteed portable among different systems operating Oracle Database, up to 38 digits of precision. Optionally, you can also specify a precision (total number of digits) and scale (number of digits to the right of the decimal point):

关于你的问题,我认为你的问题是在ADF中,而不是在Parquet中。

定义精度和小数位数后,ADF 对 Oracle Number 使用此转换:

NUMBER (p,s)    Decimal, String (if p > 28)

ADF Oracle data type conversions

也许您必须咨询 Microsoft Azure 支持,因为很明显它应该在 ADF 中转换为小数,但要保持 10 的精度。