- Sort Score
- Num 10 results
- Language All
Results 1 - 9 of 9 for ToFloat (0.81 seconds)
-
internal/s3select/sql/value.go
return &Value{value: b} } // FromArray creates a Value from an array of values. func FromArray(a []Value) *Value { return &Value{value: a} } // ToFloat works for int and float values func (v Value) ToFloat() (val float64, ok bool) { switch x := v.value.(type) { case float64: return x, true case int64: return float64(x), true } return 0, false }
Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Sun Sep 28 20:59:21 GMT 2025 - 20.4K bytes - Click Count (0) -
internal/s3select/json/record.go
return other } // Set - sets the value for a column name. func (r *Record) Set(name string, value *sql.Value) (sql.Record, error) { var v any if b, ok := value.ToBool(); ok { v = b } else if f, ok := value.ToFloat(); ok { v = f } else if i, ok := value.ToInt(); ok { v = i } else if t, ok := value.ToTimestamp(); ok { v = sql.FormatSQLTimestamp(t) } else if s, ok := value.ToString(); ok { v = s
Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 5.2K bytes - Click Count (0) -
internal/s3select/sql/evaluate.go
return false } for i := range aA { if !cmp(aA[i], bA[i]) { return false } } return true } // Try as numbers aF, aOK := a.ToFloat() bF, bOK := b.ToFloat() diff := math.Abs(aF - bF) return aOK && bOK && diff < floatCmpTolerance } var rhs Value var err error var eltVal *Value switch { case e.JPathExpr != nil:Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 12K bytes - Click Count (0) -
internal/s3select/sql/aggregation.go
case aggFnCount: // For all non-null values, the count is incremented. e.aggregate.runningCount++ case aggFnAvg, aggFnSum: e.aggregate.runningCount++ // Convert to float. f, ok := argVal.ToFloat() if !ok { return fmt.Errorf("Could not convert value %v (%s) to a number", argVal.value, argVal.GetTypeString()) } argVal.setFloat(f) err = e.aggregate.runningSum.arithOp(opPlus, argVal)Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Sat Dec 23 07:19:11 GMT 2023 - 7.9K bytes - Click Count (0) -
internal/s3select/sql/funceval.go
} func handleDateAdd(r Record, d *DateAddFunc, tableAlias string) (*Value, error) { q, err := d.Quantity.evalNode(r, tableAlias) if err != nil { return nil, err } inferTypeForArithOp(q) qty, ok := q.ToFloat() if !ok { return nil, fmt.Errorf("QUANTITY must be a numeric argument to %s()", sqlFnDateAdd) } ts, err := d.Timestamp.evalNode(r, tableAlias) if err != nil { return nil, err }
Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Sun Sep 28 20:59:21 GMT 2025 - 13.2K bytes - Click Count (0) -
mockwebserver-deprecated/src/test/java/okhttp3/mockwebserver/MockWebServerTest.kt
Thread.sleep(100) } } catch (e: IOException) { break } i++ } // Halfway +/- 0.5% assertThat(i.toFloat()).isCloseTo(512f, 5f) } @Test fun disconnectResponseHalfway() { server.enqueue( MockResponse() .setBody("ab")
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Thu Jul 03 13:16:34 GMT 2025 - 22.3K bytes - Click Count (0) -
api/go1.6.txt
pkg go/build, const IgnoreVendor = 8 pkg go/build, const IgnoreVendor ImportMode pkg go/build, type Package struct, InvalidGoFiles []string pkg go/constant, func ToComplex(Value) Value pkg go/constant, func ToFloat(Value) Value pkg go/constant, func ToInt(Value) Value pkg go/constant, type Value interface, ExactString() string pkg go/types, method (*Package) SetName(string) pkg go/types, type ImportMode int
Created: Tue Dec 30 11:13:12 GMT 2025 - Last Modified: Wed Jan 13 23:40:13 GMT 2016 - 12.9K bytes - Click Count (0) -
mockwebserver/src/test/java/mockwebserver3/MockWebServerTest.kt
Thread.sleep(100) } } catch (e: IOException) { break } i++ } // Halfway +/- 0.5% assertThat(i.toFloat()).isCloseTo(512f, 5f) } @Test fun disconnectResponseHalfway() { server.enqueue( MockResponse .Builder() .body("ab") .onResponseBody(CloseSocket())
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Sun Aug 03 22:38:00 GMT 2025 - 28K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/CallTest.kt
assertFailsWith<IOException> { call.execute() } val elapsedNanos = System.nanoTime() - startNanos assertThat(TimeUnit.NANOSECONDS.toMillis(elapsedNanos).toFloat()) .isCloseTo(cancelDelayMillis.toFloat(), 100f) } @Test fun cancelImmediatelyAfterEnqueue() { server.enqueue(MockResponse()) val latch = CountDownLatch(1) client = client
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 147.4K bytes - Click Count (0)