Skip to content

Commit

Permalink
support allowDecimalPrecisionLoss
Browse files Browse the repository at this point in the history
Signed-off-by: Yuan Zhou <[email protected]>
  • Loading branch information
zhouyuan committed Aug 25, 2023
1 parent 8d735d1 commit 77c1755
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions cpp/velox/compute/WholeStageResultIterator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,8 @@ std::unordered_map<std::string, std::string> WholeStageResultIterator::getQueryC
configs[velox::core::QueryConfig::kCastToIntByTruncate] = std::to_string(true);
// To align with Spark's behavior, allow decimal in casting string to int.
configs[velox::core::QueryConfig::kCastIntAllowDecimal] = std::to_string(true);
// To align with Spark's behavior, allow decimal precision loss or not.
configs[velox::core::QueryConfig::kAllowPrecisionLoss] = getConfigValue(confMap_, kAllowPrecisionLoss, "true");;
auto defaultTimezone = getConfigValue(confMap_, kDefaultSessionTimezone, "");
configs[velox::core::QueryConfig::kSessionTimezone] = getConfigValue(confMap_, kSessionTimezone, defaultTimezone);
// Adjust timestamp according to the above configured session timezone.
Expand Down
4 changes: 2 additions & 2 deletions ep/build-velox/src/get_velox.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@

set -exu

VELOX_REPO=https://github.com/oap-project/velox.git
VELOX_BRANCH=main
VELOX_REPO=https://github.com/zhouyuan/velox.git
VELOX_BRANCH=wip_decimal_precision_loss
VELOX_HOME=""

#Set on run gluten on HDFS
Expand Down

0 comments on commit 77c1755

Please sign in to comment.