OmniSciDB  ab4938a6a3
Analyzer Namespace Reference

Namespaces

 anonymous_namespace{Analyzer.cpp}
 

Classes

class  AggExpr
 
class  ArrayExpr
 
class  BinOper
 
class  CardinalityExpr
 
class  CaseExpr
 
class  CharLengthExpr
 
class  ColumnVar
 
class  Constant
 
class  DateaddExpr
 
class  DatediffExpr
 
class  DatetruncExpr
 
class  Estimator
 
class  Expr
 
class  ExpressionTuple
 
class  ExtractExpr
 
class  FunctionOper
 
class  FunctionOperWithCustomTypeHandling
 
class  GeoExpr
 
class  InIntegerSet
 
class  InValues
 
class  KeyForStringExpr
 
class  LikeExpr
 
class  LikelihoodExpr
 
class  LowerExpr
 Expression class for the LOWER (lowercase) string function. The "arg" constructor parameter must be an expression that resolves to a string datatype (e.g. TEXT). More...
 
class  NDVEstimator
 
class  OffsetInFragment
 
struct  OrderEntry
 
class  Query
 
class  RangeTableEntry
 
class  RegexpExpr
 
class  Subquery
 
class  TargetEntry
 
class  UOper
 
class  Var
 
class  WindowFunction
 

Typedefs

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

◆ DomainSet

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

Definition at line 61 of file Analyzer.h.

◆ ExpressionPtr

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

Definition at line 180 of file Analyzer.h.

◆ ExpressionPtrList

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

Definition at line 181 of file Analyzer.h.

◆ ExpressionPtrVector

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

Definition at line 182 of file Analyzer.h.

Function Documentation

◆ Datum_equal()

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

Definition at line 1981 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, kMULTIPOLYGON, kNUMERIC, kPOINT, kPOLYGON, kSMALLINT, kTEXT, kTIME, kTIMESTAMP, kTINYINT, kVARCHAR, Datum::smallintval, Datum::stringval, Datum::tinyintval, and UNREACHABLE.

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

1981  {
1982  switch (ti.get_type()) {
1983  case kBOOLEAN:
1984  return val1.boolval == val2.boolval;
1985  case kCHAR:
1986  case kVARCHAR:
1987  case kTEXT:
1988  return *val1.stringval == *val2.stringval;
1989  case kNUMERIC:
1990  case kDECIMAL:
1991  case kBIGINT:
1992  return val1.bigintval == val2.bigintval;
1993  case kINT:
1994  return val1.intval == val2.intval;
1995  case kSMALLINT:
1996  return val1.smallintval == val2.smallintval;
1997  case kTINYINT:
1998  return val1.tinyintval == val2.tinyintval;
1999  case kFLOAT:
2000  return val1.floatval == val2.floatval;
2001  case kDOUBLE:
2002  return val1.doubleval == val2.doubleval;
2003  case kTIME:
2004  case kTIMESTAMP:
2005  case kDATE:
2006  case kINTERVAL_DAY_TIME:
2007  case kINTERVAL_YEAR_MONTH:
2008  return val1.bigintval == val2.bigintval;
2009  case kPOINT:
2010  case kLINESTRING:
2011  case kPOLYGON:
2012  case kMULTIPOLYGON:
2013  return *val1.stringval == *val2.stringval;
2014  default:
2015  throw std::runtime_error("Unrecognized type for Constant Datum equality: " +
2016  ti.get_type_name());
2017  }
2018  UNREACHABLE();
2019  return false;
2020 }
int8_t tinyintval
Definition: sqltypes.h:133
Definition: sqltypes.h:50
bool boolval
Definition: sqltypes.h:132
#define UNREACHABLE()
Definition: Logger.h:241
int32_t intval
Definition: sqltypes.h:135
float floatval
Definition: sqltypes.h:137
int64_t bigintval
Definition: sqltypes.h:136
int16_t smallintval
Definition: sqltypes.h:134
std::string * stringval
Definition: sqltypes.h:141
Definition: sqltypes.h:53
Definition: sqltypes.h:54
std::string get_type_name() const
Definition: sqltypes.h:361
Definition: sqltypes.h:42
HOST DEVICE SQLTypes get_type() const
Definition: sqltypes.h:258
Definition: sqltypes.h:46
double doubleval
Definition: sqltypes.h:138
+ Here is the call graph for this function:
+ Here is the caller graph for this function: