Header And Logo

PostgreSQL
| The world's most advanced open source database.

nodeHash.h

Go to the documentation of this file.
00001 /*-------------------------------------------------------------------------
00002  *
00003  * nodeHash.h
00004  *    prototypes for nodeHash.c
00005  *
00006  *
00007  * Portions Copyright (c) 1996-2013, PostgreSQL Global Development Group
00008  * Portions Copyright (c) 1994, Regents of the University of California
00009  *
00010  * src/include/executor/nodeHash.h
00011  *
00012  *-------------------------------------------------------------------------
00013  */
00014 #ifndef NODEHASH_H
00015 #define NODEHASH_H
00016 
00017 #include "nodes/execnodes.h"
00018 
00019 extern HashState *ExecInitHash(Hash *node, EState *estate, int eflags);
00020 extern TupleTableSlot *ExecHash(HashState *node);
00021 extern Node *MultiExecHash(HashState *node);
00022 extern void ExecEndHash(HashState *node);
00023 extern void ExecReScanHash(HashState *node);
00024 
00025 extern HashJoinTable ExecHashTableCreate(Hash *node, List *hashOperators,
00026                     bool keepNulls);
00027 extern void ExecHashTableDestroy(HashJoinTable hashtable);
00028 extern void ExecHashTableInsert(HashJoinTable hashtable,
00029                     TupleTableSlot *slot,
00030                     uint32 hashvalue);
00031 extern bool ExecHashGetHashValue(HashJoinTable hashtable,
00032                      ExprContext *econtext,
00033                      List *hashkeys,
00034                      bool outer_tuple,
00035                      bool keep_nulls,
00036                      uint32 *hashvalue);
00037 extern void ExecHashGetBucketAndBatch(HashJoinTable hashtable,
00038                           uint32 hashvalue,
00039                           int *bucketno,
00040                           int *batchno);
00041 extern bool ExecScanHashBucket(HashJoinState *hjstate, ExprContext *econtext);
00042 extern void ExecPrepHashTableForUnmatched(HashJoinState *hjstate);
00043 extern bool ExecScanHashTableForUnmatched(HashJoinState *hjstate,
00044                               ExprContext *econtext);
00045 extern void ExecHashTableReset(HashJoinTable hashtable);
00046 extern void ExecHashTableResetMatchFlags(HashJoinTable hashtable);
00047 extern void ExecChooseHashTableSize(double ntuples, int tupwidth, bool useskew,
00048                         int *numbuckets,
00049                         int *numbatches,
00050                         int *num_skew_mcvs);
00051 extern int  ExecHashGetSkewBucket(HashJoinTable hashtable, uint32 hashvalue);
00052 
00053 #endif   /* NODEHASH_H */