Impala
Impalaistheopensource,nativeanalyticdatabaseforApacheHadoop.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
aggregate-functions.cc File Reference
#include "exprs/aggregate-functions.h"
#include <math.h>
#include <sstream>
#include <algorithm>
#include <boost/random/ranlux.hpp>
#include <boost/random/uniform_int.hpp>
#include "common/logging.h"
#include "runtime/decimal-value.h"
#include "runtime/string-value.h"
#include "runtime/timestamp-value.h"
#include "exprs/anyval-util.h"
#include "common/names.h"
Include dependency graph for aggregate-functions.cc:

Go to the source code of this file.

Classes

struct  impala::AvgState
 
struct  impala::DecimalAvgState
 
struct  impala::ReservoirSample< T >
 
struct  impala::ReservoirSample< StringVal >
 
struct  impala::ReservoirSampleState< T >
 
struct  impala::KnuthVarianceState
 
struct  impala::RankState
 

Namespaces

 impala
 This file contains type definitions that are used throughout the code base.
 

Typedefs

typedef int impala::StringConcatHeader
 

Functions

template<typename T >
StringVal impala::ToStringVal (FunctionContext *context, T val)
 
static void impala::SetDistinctEstimateBit (uint8_t *bitmap, uint32_t row_index, uint32_t bit_index)
 
static bool impala::GetDistinctEstimateBit (uint8_t *bitmap, uint32_t row_index, uint32_t bit_index)
 
string impala::DistinctEstimateBitMapToString (uint8_t *v)
 
double impala::DistinceEstimateFinalize (const StringVal &src)
 
template<typename T >
bool impala::SampleValLess (const ReservoirSample< T > &i, const ReservoirSample< T > &j)
 
template<>
bool impala::SampleValLess (const ReservoirSample< StringVal > &i, const ReservoirSample< StringVal > &j)
 
template<>
bool impala::SampleValLess (const ReservoirSample< DecimalVal > &i, const ReservoirSample< DecimalVal > &j)
 
template<>
bool impala::SampleValLess (const ReservoirSample< TimestampVal > &i, const ReservoirSample< TimestampVal > &j)
 
template<typename T >
bool impala::SampleKeyGreater (const ReservoirSample< T > &i, const ReservoirSample< T > &j)
 
template<typename T >
void impala::PrintSample (const ReservoirSample< T > &v, ostream *os)
 
template<>
void impala::PrintSample (const ReservoirSample< TinyIntVal > &v, ostream *os)
 
template<>
void impala::PrintSample (const ReservoirSample< StringVal > &v, ostream *os)
 
template<>
void impala::PrintSample (const ReservoirSample< DecimalVal > &v, ostream *os)
 
template<>
void impala::PrintSample (const ReservoirSample< TimestampVal > &v, ostream *os)
 
double impala::ComputeKnuthVariance (const KnuthVarianceState &state, bool pop)
 

Variables

static const StringVal impala::DEFAULT_STRING_CONCAT_DELIM ((uint8_t *)", ", 2)
 
static const int impala::NUM_PC_BITMAPS = 64
 
static const int impala::PC_BITMAP_LENGTH = 32
 
static const float impala::PC_THETA = 0.77351f
 
static const int impala::NUM_BUCKETS = 100
 
static const int impala::NUM_SAMPLES_PER_BUCKET = 200
 
static const int impala::NUM_SAMPLES = NUM_BUCKETS * NUM_SAMPLES_PER_BUCKET
 
static const int impala::MAX_STRING_SAMPLE_LEN = 10