snowflakedb / spark-snowflake

Snowflake Data Source for Apache Spark.
http://www.snowflake.net
Apache License 2.0
215 stars 99 forks source link

Why is the JDBC_TREAT_DECIMAL_AS_INT parameter default false #441

Open danielsomekh opened 2 years ago

danielsomekh commented 2 years ago

What's the purpose of snowflake not treating snowflake Number(38, 0) type as spark LongType by default and instead treating it as DecimalType(38,0)?

I see the JDBC_TREAT_DECIMAL_AS_INT flag is hardcoded (with the ability to override via jdbc properties) when getting a Connection.

What is the impact of flipping this flag true? I obviously don't have access to the JIRA and can't find any other info about why this is a parameter or the default parameter value is false.

JDBC code using flag Spark connector docs

MasterDDT commented 2 years ago

I'm also curious about this. The commit is https://github.com/snowflakedb/snowflake-jdbc/commit/e1c9d26dd3ae552a606842137ff8497b090aa9d4 and I also dont have access to https://snowflakecomputing.atlassian.net/browse/SNOW-33227 cc @howryu @sfc-gh-stakeda @sfc-gh-mkinster