OmniSciDB  c0231cc57d
 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  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  JsonValueStringOper
 
class  Base64EncodeStringOper
 
class  Base64DecodeStringOper
 
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 65 of file Analyzer.h.

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

Definition at line 187 of file Analyzer.h.

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

Definition at line 188 of file Analyzer.h.

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

Definition at line 189 of file Analyzer.h.

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

Definition at line 4006 of file Analyzer.cpp.

Function Documentation

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

Definition at line 2203 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==().

2203  {
2204  switch (ti.get_type()) {
2205  case kBOOLEAN:
2206  return val1.boolval == val2.boolval;
2207  case kCHAR:
2208  case kVARCHAR:
2209  case kTEXT:
2210  return *val1.stringval == *val2.stringval;
2211  case kNUMERIC:
2212  case kDECIMAL:
2213  case kBIGINT:
2214  return val1.bigintval == val2.bigintval;
2215  case kINT:
2216  return val1.intval == val2.intval;
2217  case kSMALLINT:
2218  return val1.smallintval == val2.smallintval;
2219  case kTINYINT:
2220  return val1.tinyintval == val2.tinyintval;
2221  case kFLOAT:
2222  return val1.floatval == val2.floatval;
2223  case kDOUBLE:
2224  return val1.doubleval == val2.doubleval;
2225  case kTIME:
2226  case kTIMESTAMP:
2227  case kDATE:
2228  case kINTERVAL_DAY_TIME:
2229  case kINTERVAL_YEAR_MONTH:
2230  return val1.bigintval == val2.bigintval;
2231  case kPOINT:
2232  case kMULTIPOINT:
2233  case kLINESTRING:
2234  case kMULTILINESTRING:
2235  case kPOLYGON:
2236  case kMULTIPOLYGON:
2237  return *val1.stringval == *val2.stringval;
2238  default:
2239  throw std::runtime_error("Unrecognized type for Constant Datum equality: " +
2240  ti.get_type_name());
2241  }
2242  UNREACHABLE();
2243  return false;
2244 }
int8_t tinyintval
Definition: sqltypes.h:232
Definition: sqltypes.h:63
int8_t boolval
Definition: sqltypes.h:231
#define UNREACHABLE()
Definition: Logger.h:266
HOST DEVICE SQLTypes get_type() const
Definition: sqltypes.h:404
int32_t intval
Definition: sqltypes.h:234
float floatval
Definition: sqltypes.h:236
int64_t bigintval
Definition: sqltypes.h:235
int16_t smallintval
Definition: sqltypes.h:233
std::string * stringval
Definition: sqltypes.h:240
Definition: sqltypes.h:66
Definition: sqltypes.h:67
std::string get_type_name() const
Definition: sqltypes.h:528
Definition: sqltypes.h:55
Definition: sqltypes.h:59
double doubleval
Definition: sqltypes.h:237

+ Here is the call graph for this function:

+ Here is the caller graph for this function: