|
| template<class SRC, class DST> |
| static DST | Operation (SRC input) |
◆ Operation() [1/8]
template<class SRC, class DST>
| DST duckdb::Cast::Operation |
( |
SRC | input | ) |
|
|
inlinestatic |
31245 {
31246 DST result;
31247 if (!TryCast::Operation(input, result)) {
31248 throw InvalidInputException(CastExceptionText<SRC, DST>(input));
31249 }
31250 return result;
31251 }
◆ Operation() [2/8]
90254 {
90256}
static DUCKDB_API date_t FromCString(const char *str, idx_t len, bool strict=false)
Convert a string in the format "YYYY-MM-DD" to a date object.
Definition duckdb.cpp:117506
◆ Operation() [3/8]
90277 {
90278 return Time::FromCString(input.GetData(), input.GetSize());
90279}
◆ Operation() [4/8]
90308 {
90309 dtime_ns_t result;
90310 if (!TryCast::Operation(input, result, false)) {
90311 throw ConversionException(Time::ConversionError(input));
90312 }
90313 return result;
90314}
◆ Operation() [5/8]
90336 {
90337 dtime_tz_t result;
90338 if (!TryCast::Operation(input, result, false)) {
90339 throw ConversionException(Time::ConversionError(input));
90340 }
90341 return result;
90342}
◆ Operation() [6/8]
90403 {
90404 return Timestamp::FromCString(input.GetData(), input.GetSize(), false);
90405}
◆ Operation() [7/8]
90408 {
90409 return timestamp_tz_t(Timestamp::FromCString(input.GetData(), input.GetSize(), true));
90410}
◆ Operation() [8/8]
90413 {
90415 const auto ts = Timestamp::FromCString(input.GetData(), input.GetSize(), false, &nanos);
90416 timestamp_ns_t result;
90418 throw ConversionException(Timestamp::RangeError(input));
90419 }
90420 return result;
90421}
static DUCKDB_API bool TryFromTimestampNanos(timestamp_t ts, int32_t nanos, timestamp_ns_t &result)
Scale up to ns.
Definition duckdb.cpp:129588
The documentation for this struct was generated from the following file: