OmniSciDB  a5dc49c757
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Analyzer Namespace Reference

Namespaces

 anonymous_namespace{Analyzer.cpp}
 

Classes

class  Expr
 
class  ColumnVar
 
class  ExpressionTuple
 
class  Var
 
class  Constant
 
class  UOper
 
class  BinOper
 
class  RangeOper
 
class  Subquery
 
class  InValues
 
class  InIntegerSet
 
class  MLPredictExpr
 
class  PCAProjectExpr
 
class  CharLengthExpr
 
class  KeyForStringExpr
 
class  SampleRatioExpr
 
class  CardinalityExpr
 
class  LikeExpr
 
class  RegexpExpr
 
class  WidthBucketExpr
 
class  LikelihoodExpr
 
class  AggExpr
 
class  CaseExpr
 
class  ExtractExpr
 
class  DateaddExpr
 
class  DatediffExpr
 
class  DatetruncExpr
 
class  StringOper
 Expression class for string functions The "arg" constructor parameter must be an expression that resolves to a string datatype (e.g. TEXT). More...
 
class  LowerStringOper
 
class  UpperStringOper
 
class  InitCapStringOper
 
class  ReverseStringOper
 
class  RepeatStringOper
 
class  ConcatStringOper
 
class  PadStringOper
 
class  TrimStringOper
 
class  SubstringStringOper
 
class  OverlayStringOper
 
class  ReplaceStringOper
 
class  SplitPartStringOper
 
class  RegexpReplaceStringOper
 
class  RegexpSubstrStringOper
 
class  RegexpCountStringOper
 
class  JsonValueStringOper
 
class  Base64EncodeStringOper
 
class  Base64DecodeStringOper
 
class  UrlEncodeStringOper
 
class  UrlDecodeStringOper
 
class  TryStringCastOper
 
class  PositionStringOper
 
class  JarowinklerSimilarityStringOper
 
class  LevenshteinDistanceStringOper
 
class  HashStringOper
 
class  FunctionOper
 
class  FunctionOperWithCustomTypeHandling
 
class  OffsetInFragment
 
struct  OrderEntry
 
class  WindowFrame
 
class  WindowFunction
 
class  ArrayExpr
 
class  GeoUOper
 
class  GeoBinOper
 
class  TargetEntry
 
class  Query
 
class  GeoExpr
 
class  GeoColumnVar
 
class  GeoConstant
 
class  GeoOperator
 
class  GeoTransformOperator
 
class  RangeTableEntry
 
class  Estimator
 
class  NDVEstimator
 
class  LargeNDVEstimator
 

Typedefs

using LiteralArgMap = std::map< size_t, std::pair< SQLTypes, Datum >>
 
using DomainSet = std::list< const Expr * >
 
using ExpressionPtr = std::shared_ptr< Analyzer::Expr >
 
using ExpressionPtrList = std::list< ExpressionPtr >
 
using ExpressionPtrVector = std::vector< ExpressionPtr >
 

Functions

bool Datum_equal (const SQLTypeInfo &ti, Datum val1, Datum val2)
 

Typedef Documentation

using Analyzer::DomainSet = typedef std::list<const Expr*>

Definition at line 62 of file Analyzer.h.

using Analyzer::ExpressionPtr = typedef std::shared_ptr<Analyzer::Expr>

Definition at line 184 of file Analyzer.h.

using Analyzer::ExpressionPtrList = typedef std::list<ExpressionPtr>

Definition at line 185 of file Analyzer.h.

using Analyzer::ExpressionPtrVector = typedef std::vector<ExpressionPtr>

Definition at line 186 of file Analyzer.h.

using Analyzer::LiteralArgMap = typedef std::map<size_t, std::pair<SQLTypes, Datum>>

Definition at line 4308 of file Analyzer.cpp.

Function Documentation

bool Analyzer::Datum_equal ( const SQLTypeInfo ti,
Datum  val1,
Datum  val2 
)

Definition at line 2291 of file Analyzer.cpp.

References Datum::bigintval, Datum::boolval, Datum::doubleval, Datum::floatval, SQLTypeInfo::get_type(), SQLTypeInfo::get_type_name(), Datum::intval, kBIGINT, kBOOLEAN, kCHAR, kDATE, kDECIMAL, kDOUBLE, kFLOAT, kINT, kINTERVAL_DAY_TIME, kINTERVAL_YEAR_MONTH, kLINESTRING, kMULTILINESTRING, kMULTIPOINT, kMULTIPOLYGON, kNUMERIC, kPOINT, kPOLYGON, kSMALLINT, kTEXT, kTIME, kTIMESTAMP, kTINYINT, kVARCHAR, Datum::smallintval, Datum::stringval, Datum::tinyintval, and UNREACHABLE.

Referenced by Analyzer::Constant::operator==().

2291  {
2292  switch (ti.get_type()) {
2293  case kBOOLEAN:
2294  return val1.boolval == val2.boolval;
2295  case kCHAR:
2296  case kVARCHAR:
2297  case kTEXT:
2298  return *val1.stringval == *val2.stringval;
2299  case kNUMERIC:
2300  case kDECIMAL:
2301  case kBIGINT:
2302  return val1.bigintval == val2.bigintval;
2303  case kINT:
2304  return val1.intval == val2.intval;
2305  case kSMALLINT:
2306  return val1.smallintval == val2.smallintval;
2307  case kTINYINT:
2308  return val1.tinyintval == val2.tinyintval;
2309  case kFLOAT:
2310  return val1.floatval == val2.floatval;
2311  case kDOUBLE:
2312  return val1.doubleval == val2.doubleval;
2313  case kTIME:
2314  case kTIMESTAMP:
2315  case kDATE:
2316  case kINTERVAL_DAY_TIME:
2317  case kINTERVAL_YEAR_MONTH:
2318  return val1.bigintval == val2.bigintval;
2319  case kPOINT:
2320  case kMULTIPOINT:
2321  case kLINESTRING:
2322  case kMULTILINESTRING:
2323  case kPOLYGON:
2324  case kMULTIPOLYGON:
2325  return *val1.stringval == *val2.stringval;
2326  default:
2327  throw std::runtime_error("Unrecognized type for Constant Datum equality: " +
2328  ti.get_type_name());
2329  }
2330  UNREACHABLE();
2331  return false;
2332 }
int8_t tinyintval
Definition: Datum.h:73
Definition: sqltypes.h:76
int8_t boolval
Definition: Datum.h:72
#define UNREACHABLE()
Definition: Logger.h:338
HOST DEVICE SQLTypes get_type() const
Definition: sqltypes.h:391
int32_t intval
Definition: Datum.h:75
float floatval
Definition: Datum.h:77
int64_t bigintval
Definition: Datum.h:76
int16_t smallintval
Definition: Datum.h:74
std::string * stringval
Definition: Datum.h:81
Definition: sqltypes.h:79
Definition: sqltypes.h:80
std::string get_type_name() const
Definition: sqltypes.h:484
Definition: sqltypes.h:68
Definition: sqltypes.h:72
double doubleval
Definition: Datum.h:78

+ Here is the call graph for this function:

+ Here is the caller graph for this function: