MCPcopy Create free account
hub / github.com/questdb/questdb / fromLong

Method fromLong

core/src/main/java/io/questdb/std/Decimal256.java:590–596  ·  view source on GitHub ↗

Create Decimal256 from a long value with specified scale. @param value the long value @param scale the desired scale @return new Decimal256 instance @throws NumericException if scale is invalid

(long value, int scale)

Source from the content-addressed store, hash-verified

588 * @throws NumericException if scale is invalid
589 */
590 public static Decimal256 fromLong(long value, int scale) {
591 validateScale(scale);
592
593 Decimal256 result = new Decimal256();
594 result.ofLong(value, scale);
595 return result;
596 }
597
598 /**
599 * Extracts the digit at a specific power-of-ten position from a 256-bit decimal number.

Calls 2

validateScaleMethod · 0.95
ofLongMethod · 0.95