OmniSciDB  72c90bc290
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
anonymous_namespace{ExtensionFunctionsBinding.cpp} Namespace Reference

Functions

ExtArgumentType get_column_arg_elem_type (const ExtArgumentType ext_arg_column_type)
 
ExtArgumentType get_column_list_arg_elem_type (const ExtArgumentType ext_arg_column_list_type)
 
ExtArgumentType get_array_arg_elem_type (const ExtArgumentType ext_arg_array_type)
 
static int match_numeric_argument (const SQLTypeInfo &arg_type_info, const bool is_arg_literal, const ExtArgumentType &sig_ext_arg_type, int32_t &penalty_score)
 
static int match_arguments (const SQLTypeInfo &arg_type, const bool is_arg_literal, int sig_pos, const std::vector< ExtArgumentType > &sig_types, int &penalty_score)
 
bool is_valid_identifier (std::string str)
 

Function Documentation

ExtArgumentType anonymous_namespace{ExtensionFunctionsBinding.cpp}::get_array_arg_elem_type ( const ExtArgumentType  ext_arg_array_type)

Definition at line 147 of file ExtensionFunctionsBinding.cpp.

References ArrayBool, ArrayDouble, ArrayFloat, ArrayInt16, ArrayInt32, ArrayInt64, ArrayInt8, ArrayTextEncodingDict, ArrayTextEncodingNone, Bool, Double, Float, Int16, Int32, Int64, Int8, TextEncodingDict, TextEncodingNone, and UNREACHABLE.

Referenced by match_arguments().

+ Here is the caller graph for this function:

ExtArgumentType anonymous_namespace{ExtensionFunctionsBinding.cpp}::get_column_arg_elem_type ( const ExtArgumentType  ext_arg_column_type)

Definition at line 36 of file ExtensionFunctionsBinding.cpp.

References ArrayBool, ArrayDouble, ArrayFloat, ArrayInt16, ArrayInt32, ArrayInt64, ArrayInt8, ArrayTextEncodingDict, Bool, ColumnArrayBool, ColumnArrayDouble, ColumnArrayFloat, ColumnArrayInt16, ColumnArrayInt32, ColumnArrayInt64, ColumnArrayInt8, ColumnArrayTextEncodingDict, ColumnBool, ColumnDouble, ColumnFloat, ColumnGeoLineString, ColumnGeoMultiLineString, ColumnGeoMultiPoint, ColumnGeoMultiPolygon, ColumnGeoPoint, ColumnGeoPolygon, ColumnInt16, ColumnInt32, ColumnInt64, ColumnInt8, ColumnTextEncodingDict, ColumnTextEncodingNone, ColumnTimestamp, Double, Float, GeoLineString, GeoMultiLineString, GeoMultiPoint, GeoMultiPolygon, GeoPoint, GeoPolygon, Int16, Int32, Int64, Int8, TextEncodingDict, TextEncodingNone, Timestamp, and UNREACHABLE.

Referenced by match_arguments().

36  {
37  switch (ext_arg_column_type) {
39  return ExtArgumentType::Int8;
51  return ExtArgumentType::Bool;
86  default:
87  UNREACHABLE();
88  }
89  return ExtArgumentType{};
90 }
#define UNREACHABLE()
Definition: Logger.h:338

+ Here is the caller graph for this function:

ExtArgumentType anonymous_namespace{ExtensionFunctionsBinding.cpp}::get_column_list_arg_elem_type ( const ExtArgumentType  ext_arg_column_list_type)

Definition at line 92 of file ExtensionFunctionsBinding.cpp.

References ArrayBool, ArrayDouble, ArrayFloat, ArrayInt16, ArrayInt32, ArrayInt64, ArrayInt8, ArrayTextEncodingDict, Bool, ColumnListArrayBool, ColumnListArrayDouble, ColumnListArrayFloat, ColumnListArrayInt16, ColumnListArrayInt32, ColumnListArrayInt64, ColumnListArrayInt8, ColumnListArrayTextEncodingDict, ColumnListBool, ColumnListDouble, ColumnListFloat, ColumnListGeoLineString, ColumnListGeoMultiLineString, ColumnListGeoMultiPoint, ColumnListGeoMultiPolygon, ColumnListGeoPoint, ColumnListGeoPolygon, ColumnListInt16, ColumnListInt32, ColumnListInt64, ColumnListInt8, ColumnListTextEncodingDict, ColumnListTextEncodingNone, Double, Float, GeoLineString, GeoMultiLineString, GeoMultiPoint, GeoMultiPolygon, GeoPoint, GeoPolygon, Int16, Int32, Int64, Int8, TextEncodingDict, TextEncodingNone, and UNREACHABLE.

Referenced by match_arguments().

93  {
94  switch (ext_arg_column_list_type) {
96  return ExtArgumentType::Int8;
100  return ExtArgumentType::Int32;
102  return ExtArgumentType::Int64;
104  return ExtArgumentType::Float;
108  return ExtArgumentType::Bool;
141  default:
142  UNREACHABLE();
143  }
144  return ExtArgumentType{};
145 }
#define UNREACHABLE()
Definition: Logger.h:338

+ Here is the caller graph for this function:

bool anonymous_namespace{ExtensionFunctionsBinding.cpp}::is_valid_identifier ( std::string  str)

Definition at line 527 of file ExtensionFunctionsBinding.cpp.

Referenced by bind_function().

527  {
528  if (!str.size()) {
529  return false;
530  }
531 
532  if (!(std::isalpha(str[0]) || str[0] == '_')) {
533  return false;
534  }
535 
536  for (size_t i = 1; i < str.size(); i++) {
537  if (!(std::isalnum(str[i]) || str[i] == '_')) {
538  return false;
539  }
540  }
541 
542  return true;
543 }

+ Here is the caller graph for this function:

static int anonymous_namespace{ExtensionFunctionsBinding.cpp}::match_arguments ( const SQLTypeInfo arg_type,
const bool  is_arg_literal,
int  sig_pos,
const std::vector< ExtArgumentType > &  sig_types,
int &  penalty_score 
)
static

Definition at line 265 of file ExtensionFunctionsBinding.cpp.

References CHECK, DayTimeInterval, ext_arg_type_to_type_info(), GeoLineString, GeoMultiLineString, GeoMultiPoint, GeoMultiPolygon, GeoPoint, GeoPolygon, get_array_arg_elem_type(), get_column_arg_elem_type(), get_column_list_arg_elem_type(), SQLTypeInfo::get_compression(), SQLTypeInfo::get_elem_type(), SQLTypeInfo::get_type(), SQLTypeInfo::get_type_name(), Int64, SQLTypeInfo::is_array(), is_ext_arg_type_array(), is_ext_arg_type_column(), is_ext_arg_type_column_list(), kARRAY, kBIGINT, kBOOLEAN, kCOLUMN, kCOLUMN_LIST, kDECIMAL, kDOUBLE, kENCODING_DICT, kENCODING_NONE, kFLOAT, kINT, kINTERVAL_DAY_TIME, kINTERVAL_YEAR_MONTH, kLINESTRING, kMULTILINESTRING, kMULTIPOINT, kMULTIPOLYGON, kNULLT, kNUMERIC, kPOINT, kPOLYGON, kSMALLINT, kTEXT, kTIMESTAMP, kTINYINT, kVARCHAR, match_numeric_argument(), PBool, PDouble, PFloat, PInt16, PInt32, PInt64, PInt8, TextEncodingDict, TextEncodingNone, Timestamp, to_string(), ExtensionFunctionsWhitelist::toString(), UNREACHABLE, and YearMonthTimeInterval.

Referenced by bind_function().

269  {
270  /*
271  Returns non-negative integer `offset` if `arg_type` and
272  `sig_types[sig_pos:sig_pos + offset]` match.
273 
274  The `offset` value can be interpreted as the number of extension
275  function arguments that is consumed by the given `arg_type`. For
276  instance, for scalar types the offset is always 1, for array
277  types the offset is 2: one argument for array pointer value and
278  one argument for the array size value, etc.
279 
280  Returns -1 when the types of an argument and the corresponding
281  extension function argument(s) mismatch, or when downcasting would
282  be effective.
283 
284  In case of non-negative `offset` result, the function updates
285  penalty_score argument as follows:
286 
287  add 1000 if arg_type is non-scalar, otherwise:
288  add 1000 * sizeof(sig_type) / sizeof(arg_type)
289  add 1000000 if type kinds differ (integer vs double, for instance)
290 
291  */
292  int max_pos = sig_types.size() - 1;
293  if (sig_pos > max_pos) {
294  return -1;
295  }
296  auto sig_type = sig_types[sig_pos];
297  switch (arg_type.get_type()) {
298  case kBOOLEAN:
299  case kTINYINT:
300  case kSMALLINT:
301  case kINT:
302  case kBIGINT:
303  case kFLOAT:
304  case kDOUBLE:
305  case kDECIMAL:
306  case kNUMERIC:
307  return match_numeric_argument(arg_type, is_arg_literal, sig_type, penalty_score);
308  case kPOINT:
309  case kMULTIPOINT:
310  case kLINESTRING:
311  if ((sig_type == ExtArgumentType::PInt8 || sig_type == ExtArgumentType::PInt16 ||
312  sig_type == ExtArgumentType::PInt32 || sig_type == ExtArgumentType::PInt64 ||
313  sig_type == ExtArgumentType::PFloat || sig_type == ExtArgumentType::PDouble) &&
314  sig_pos < max_pos && sig_types[sig_pos + 1] == ExtArgumentType::Int64) {
315  penalty_score += 1000;
316  return 2;
317  } else if ((sig_type == ExtArgumentType::GeoPoint &&
318  arg_type.get_type() == kPOINT) ||
319  (sig_type == ExtArgumentType::GeoMultiPoint &&
320  arg_type.get_type() == kMULTIPOINT) ||
321  (sig_type == ExtArgumentType::GeoLineString &&
322  arg_type.get_type() == kLINESTRING)) {
323  penalty_score += 1000;
324  return 1;
325  }
326  return -1;
327  case kMULTILINESTRING:
328  if (sig_type == ExtArgumentType::PInt8 && sig_pos + 3 < max_pos &&
329  sig_types[sig_pos + 1] == ExtArgumentType::Int64 &&
330  sig_types[sig_pos + 2] == ExtArgumentType::PInt8 &&
331  sig_types[sig_pos + 3] == ExtArgumentType::Int64) {
332  penalty_score += 1000;
333  return 4;
334  } else if (sig_type == ExtArgumentType::GeoMultiLineString) {
335  penalty_score += 1000;
336  return 1;
337  }
338  break;
339  case kARRAY:
340  if ((sig_type == ExtArgumentType::PInt8 || sig_type == ExtArgumentType::PInt16 ||
341  sig_type == ExtArgumentType::PInt32 || sig_type == ExtArgumentType::PInt64 ||
342  sig_type == ExtArgumentType::PFloat || sig_type == ExtArgumentType::PDouble ||
343  sig_type == ExtArgumentType::PBool) &&
344  sig_pos < max_pos && sig_types[sig_pos + 1] == ExtArgumentType::Int64) {
345  penalty_score += 1000;
346  return 2;
347  } else if (is_ext_arg_type_array(sig_type)) {
348  // array arguments must match exactly
349  CHECK(arg_type.is_array());
350  const auto sig_type_ti =
352  if (arg_type.get_elem_type().get_type() == kBOOLEAN &&
353  sig_type_ti.get_type() == kTINYINT) {
354  /* Boolean array has the same low-level structure as Int8 array. */
355  penalty_score += 1000;
356  return 1;
357  } else if (arg_type.get_elem_type().get_type() == sig_type_ti.get_type()) {
358  penalty_score += 1000;
359  return 1;
360  } else {
361  return -1;
362  }
363  }
364  break;
365  case kPOLYGON:
366  if (sig_type == ExtArgumentType::PInt8 && sig_pos + 3 < max_pos &&
367  sig_types[sig_pos + 1] == ExtArgumentType::Int64 &&
368  sig_types[sig_pos + 2] == ExtArgumentType::PInt32 &&
369  sig_types[sig_pos + 3] == ExtArgumentType::Int64) {
370  penalty_score += 1000;
371  return 4;
372  } else if (sig_type == ExtArgumentType::GeoPolygon) {
373  penalty_score += 1000;
374  return 1;
375  }
376  break;
377  case kMULTIPOLYGON:
378  if (sig_type == ExtArgumentType::PInt8 && sig_pos + 5 < max_pos &&
379  sig_types[sig_pos + 1] == ExtArgumentType::Int64 &&
380  sig_types[sig_pos + 2] == ExtArgumentType::PInt32 &&
381  sig_types[sig_pos + 3] == ExtArgumentType::Int64 &&
382  sig_types[sig_pos + 4] == ExtArgumentType::PInt32 &&
383  sig_types[sig_pos + 5] == ExtArgumentType::Int64) {
384  penalty_score += 1000;
385  return 6;
386  } else if (sig_type == ExtArgumentType::GeoMultiPolygon) {
387  penalty_score += 1000;
388  return 1;
389  }
390  break;
391  case kNULLT: // NULL maps to a pointer and size argument
392  if ((sig_type == ExtArgumentType::PInt8 || sig_type == ExtArgumentType::PInt16 ||
393  sig_type == ExtArgumentType::PInt32 || sig_type == ExtArgumentType::PInt64 ||
394  sig_type == ExtArgumentType::PFloat || sig_type == ExtArgumentType::PDouble ||
395  sig_type == ExtArgumentType::PBool) &&
396  sig_pos < max_pos && sig_types[sig_pos + 1] == ExtArgumentType::Int64) {
397  penalty_score += 1000;
398  return 2;
399  }
400  break;
401  case kCOLUMN:
402  if (is_ext_arg_type_column(sig_type)) {
403  // column arguments must match exactly
404  const auto sig_type_ti =
406  if (arg_type.get_elem_type().get_type() == kARRAY &&
407  sig_type_ti.get_type() == kARRAY) {
408  if (arg_type.get_elem_type().get_elem_type().get_type() ==
409  sig_type_ti.get_elem_type().get_type()) {
410  penalty_score += 1000;
411  return 1;
412  } else {
413  return -1;
414  }
415  } else if (arg_type.get_elem_type().get_type() == kBOOLEAN &&
416  sig_type_ti.get_type() == kTINYINT) {
417  /* Boolean column has the same low-level structure as Int8 column. */
418  penalty_score += 1000;
419  return 1;
420  } else if (arg_type.get_elem_type().get_type() == sig_type_ti.get_type()) {
421  penalty_score += 1000;
422  return 1;
423  } else {
424  return -1;
425  }
426  }
427  break;
428  case kCOLUMN_LIST:
429  if (is_ext_arg_type_column_list(sig_type)) {
430  // column_list arguments must match exactly
431  const auto sig_type_ti =
433  if (arg_type.get_elem_type().get_type() == kARRAY &&
434  sig_type_ti.get_type() == kARRAY) {
435  if (arg_type.get_elem_type().get_elem_type().get_type() ==
436  sig_type_ti.get_elem_type().get_type()) {
437  penalty_score += 1000;
438  return 1;
439  } else {
440  return -1;
441  }
442  } else if (arg_type.get_elem_type().get_type() == kBOOLEAN &&
443  sig_type_ti.get_type() == kTINYINT) {
444  /* Boolean column_list has the same low-level structure as Int8 column_list. */
445  penalty_score += 10000;
446  return 1;
447  } else if (arg_type.get_elem_type().get_type() == sig_type_ti.get_type()) {
448  penalty_score += 10000;
449  return 1;
450  } else {
451  return -1;
452  }
453  }
454  break;
455  case kVARCHAR:
456  if (sig_type != ExtArgumentType::TextEncodingNone) {
457  return -1;
458  }
459  switch (arg_type.get_compression()) {
460  case kENCODING_NONE:
461  penalty_score += 1000;
462  return 1;
463  case kENCODING_DICT:
464  return -1;
465  // Todo (todd): Evaluate when and where we can tranlate to dictionary-encoded
466  default:
467  UNREACHABLE();
468  }
469  case kTEXT:
470  switch (arg_type.get_compression()) {
471  case kENCODING_NONE:
472  if (sig_type == ExtArgumentType::TextEncodingNone) {
473  penalty_score += 1000;
474  return 1;
475  }
476  return -1;
477  case kENCODING_DICT:
478  if (sig_type == ExtArgumentType::TextEncodingDict) {
479  penalty_score += 1000;
480  return 1;
481  }
482  return -1;
483  default:
484  UNREACHABLE();
485  }
486  case kTIMESTAMP:
487  if (sig_type == ExtArgumentType::Timestamp) {
488  penalty_score += 1000;
489  return 1;
490  }
491  break;
492  case kINTERVAL_DAY_TIME:
493  if (sig_type == ExtArgumentType::DayTimeInterval) {
494  penalty_score += 1000;
495  return 1;
496  }
497  break;
498 
500  if (sig_type == ExtArgumentType::YearMonthTimeInterval) {
501  penalty_score += 1000;
502  return 1;
503  }
504  break;
505 
506  /* Not implemented types:
507  kCHAR
508  kTIME
509  kDATE
510  kGEOMETRY
511  kGEOGRAPHY
512  kEVAL_CONTEXT_TYPE
513  kVOID
514  kCURSOR
515  */
516  default:
517  throw std::runtime_error(std::string(__FILE__) + "#" + std::to_string(__LINE__) +
518  ": support for " + arg_type.get_type_name() +
519  "(type=" + std::to_string(arg_type.get_type()) + ")" +
520  +" not implemented: \n pos=" + std::to_string(sig_pos) +
521  " max_pos=" + std::to_string(max_pos) + "\n sig_types=(" +
522  ExtensionFunctionsWhitelist::toString(sig_types) + ")");
523  }
524  return -1;
525 }
ExtArgumentType get_array_arg_elem_type(const ExtArgumentType ext_arg_array_type)
bool is_ext_arg_type_column(const ExtArgumentType ext_arg_type)
#define UNREACHABLE()
Definition: Logger.h:338
ExtArgumentType get_column_list_arg_elem_type(const ExtArgumentType ext_arg_column_list_type)
HOST DEVICE SQLTypes get_type() const
Definition: sqltypes.h:391
std::string to_string(char const *&&v)
bool is_ext_arg_type_column_list(const ExtArgumentType ext_arg_type)
bool is_ext_arg_type_array(const ExtArgumentType ext_arg_type)
ExtArgumentType get_column_arg_elem_type(const ExtArgumentType ext_arg_column_type)
static int match_numeric_argument(const SQLTypeInfo &arg_type_info, const bool is_arg_literal, const ExtArgumentType &sig_ext_arg_type, int32_t &penalty_score)
Definition: sqltypes.h:79
HOST DEVICE EncodingType get_compression() const
Definition: sqltypes.h:399
std::string get_type_name() const
Definition: sqltypes.h:482
static std::string toString(const std::vector< ExtensionFunction > &ext_funcs, std::string tab="")
#define CHECK(condition)
Definition: Logger.h:291
Definition: sqltypes.h:72
SQLTypeInfo get_elem_type() const
Definition: sqltypes.h:975
bool is_array() const
Definition: sqltypes.h:583
SQLTypeInfo ext_arg_type_to_type_info(const ExtArgumentType ext_arg_type)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static int anonymous_namespace{ExtensionFunctionsBinding.cpp}::match_numeric_argument ( const SQLTypeInfo arg_type_info,
const bool  is_arg_literal,
const ExtArgumentType sig_ext_arg_type,
int32_t &  penalty_score 
)
static

Definition at line 173 of file ExtensionFunctionsBinding.cpp.

References CHECK, CHECK_GE, CHECK_GT, CHECK_LE, ext_arg_type_to_type_info(), SQLTypeInfo::get_numeric_scalar_scale(), SQLTypeInfo::get_type(), SQLTypeInfo::is_numeric_scalar_auto_castable(), kBIGINT, kBOOLEAN, kDECIMAL, kDOUBLE, kFLOAT, kINT, kNUMERIC, kSMALLINT, and kTINYINT.

Referenced by match_arguments().

176  {
177  const auto arg_type = arg_type_info.get_type();
178  CHECK(arg_type == kBOOLEAN || arg_type == kTINYINT || arg_type == kSMALLINT ||
179  arg_type == kINT || arg_type == kBIGINT || arg_type == kFLOAT ||
180  arg_type == kDOUBLE || arg_type == kDECIMAL || arg_type == kNUMERIC);
181  // Todo (todd): Add support for timestamp, date, and time types
182  const auto sig_type_info = ext_arg_type_to_type_info(sig_ext_arg_type);
183  const auto sig_type = sig_type_info.get_type();
184 
185  // If we can't legally auto-cast to sig_type, abort
186  if (!arg_type_info.is_numeric_scalar_auto_castable(sig_type_info)) {
187  return -1;
188  }
189 
190  // We now compare a measure of the scale of the sig_type with the
191  // arg_type, which provides a basis for scoring the match between
192  // the two. Note that get_numeric_scalar_scale for the most part
193  // returns the logical byte width of the type, with a few caveats
194  // for decimals and timestamps described in more depth in comments
195  // in the function itself. Also even though for example float and
196  // int types return 4 (as in 4 bytes), and double and bigint types
197  // return 8, a fp32 type cannot express every 32-bit integer (even
198  // if it can cover a larger absolute range), and an fp64 type
199  // likewise cannot express every 64-bit integer. With the aim to
200  // minimize the precision loss from casting (always precise) integer
201  // value to (imprecise) floating point value, in the case of integer
202  // inputs, we'll penalize wider floating point argument types least
203  // by a specific scale transformation (see the implementation
204  // below). For instance, casting tinyint to fp64 is prefered over
205  // casting it to fp32 to minimize precision loss.
206  const bool is_integer_to_fp_cast = (arg_type == kTINYINT || arg_type == kSMALLINT ||
207  arg_type == kINT || arg_type == kBIGINT) &&
208  (sig_type == kFLOAT || sig_type == kDOUBLE);
209 
210  const auto arg_type_relative_scale = arg_type_info.get_numeric_scalar_scale();
211  CHECK_GE(arg_type_relative_scale, 1);
212  CHECK_LE(arg_type_relative_scale, 8);
213  auto sig_type_relative_scale = sig_type_info.get_numeric_scalar_scale();
214  CHECK_GE(sig_type_relative_scale, 1);
215  CHECK_LE(sig_type_relative_scale, 8);
216 
217  if (is_integer_to_fp_cast) {
218  // transform fp scale: 4 becomes 16, 8 remains 8
219  sig_type_relative_scale = (3 - (sig_type_relative_scale >> 2)) << 3;
220  }
221 
222  // We do not allow auto-casting to types with less scale/precision
223  // within the same type family.
224  CHECK_GE(sig_type_relative_scale, arg_type_relative_scale);
225 
226  // Calculate the ratio of the sig_type by the arg_type, per the above check will be >= 1
227  const auto sig_type_scale_gain_ratio =
228  sig_type_relative_scale / arg_type_relative_scale;
229  CHECK_GE(sig_type_scale_gain_ratio, 1);
230 
231  // Following the old bespoke scoring logic this function replaces, we heavily penalize
232  // any casts that move ints to floats/doubles for the precision-loss reasons above
233  // Arguably all integers in the tinyint and smallint can be fully specified with both
234  // float and double types, but we treat them the same as int and bigint types here.
235  const int32_t type_family_cast_penalty_score = is_integer_to_fp_cast ? 1001000 : 1000;
236 
237  int32_t scale_cast_penalty_score;
238 
239  // The following logic is new. Basically there are strong reasons to
240  // prefer the promotion of constant literals to the most precise type possible, as
241  // rather than the type being inherent in the data - that is a column or columns where
242  // a user specified a type (and with any expressions on those columns following our
243  // standard sql casting logic), literal types are given to us by Calcite and do not
244  // necessarily convey any semantic intent (i.e. 10 will be an int, but 10.0 a decimal)
245  // Hence it is better to promote these types to the most precise sig_type available,
246  // while at the same time keeping column expressions as close as possible to the input
247  // types (mainly for performance, we have many float versions of various functions
248  // to allow for greater performance when the underlying data is not of double precision,
249  // and hence there is little benefit of the extra cost of computing double precision
250  // operators on this data)
251  if (is_arg_literal) {
252  scale_cast_penalty_score =
253  (8000 / arg_type_relative_scale) - (1000 * sig_type_scale_gain_ratio);
254  } else {
255  scale_cast_penalty_score = (1000 * sig_type_scale_gain_ratio);
256  }
257 
258  const auto cast_penalty_score =
259  type_family_cast_penalty_score + scale_cast_penalty_score;
260  CHECK_GT(cast_penalty_score, 0);
261  penalty_score += cast_penalty_score;
262  return 1;
263 }
#define CHECK_GE(x, y)
Definition: Logger.h:306
HOST DEVICE SQLTypes get_type() const
Definition: sqltypes.h:391
#define CHECK_GT(x, y)
Definition: Logger.h:305
bool is_numeric_scalar_auto_castable(const SQLTypeInfo &new_type_info) const
returns true if the sql_type can be cast to the type specified by new_type_info with no loss of preci...
Definition: sqltypes.h:761
#define CHECK_LE(x, y)
Definition: Logger.h:304
int32_t get_numeric_scalar_scale() const
returns integer between 1 and 8 indicating what is roughly equivalent to the logical byte size of a s...
Definition: sqltypes.h:822
#define CHECK(condition)
Definition: Logger.h:291
Definition: sqltypes.h:72
SQLTypeInfo ext_arg_type_to_type_info(const ExtArgumentType ext_arg_type)

+ Here is the call graph for this function:

+ Here is the caller graph for this function: