Skip to content

Instantly share code, notes, and snippets.

View arhimondr's full-sized avatar

Andrii Rosa arhimondr

  • Facebook
  • Boston
View GitHub Profile
[WARNING] Rule 3: org.apache.maven.plugins.enforcer.RequireReleaseDeps failed with message:
Snapshot dependencies are not allowed
Found Banned Dependency: io.airlift:log:jar:0.174-SNAPSHOT
Use 'mvn dependency:tree' to locate the source of the banned dependencies.
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] presto-root ........................................ SUCCESS [ 2.255 s]
[INFO] presto-spi ......................................... SKIPPED
[INFO] presto-plugin-toolkit .............................. SKIPPED
hive> ANALYZE TABLE <table> COMPUTE STATISTICS FOR COLUMNS;
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
- Output[rows] => [rows:bigint]
- TableCommit[hive:HiveTransactionHandle{uuid=455b2996-33e3-48a4-bad3-9e3490bf4b40}:default.nation] => [rows:bigint]
Collected statistics:
aggregations =>
NUMBER_OF_NULLS[nationkey] => [number_of_nulls-nationkey := "count"("count")]
MIN[nationkey] => [min-nationkey := "min"("min")]
MAX[nationkey] => [max-nationkey := "max"("max")]
NUMBER_OF_DISTINCT_VALUES[nationkey] => [number_of_distinct_values-nationkey := "approx_distinct"("approx_distinct")]
NUMBER_OF_NULLS[name] => [number_of_nulls-name := "count"("count_19")]
var baseCreditPercent = 10;
var promoCreditPercentFromThirtyToSixtyDays = 5;
var promoCreditPercentFromSixtyDays = 3;
var creditPercent = baseCreditPercent;
if(30 <= creditTerm && creditTerm < 60){
creditPercent = promoCreditPercentFromThirtyToSixtyDays;
} else if(60 <= creditTerm){
creditPercent = promoCreditPercentFromSixtyDays;