GPUdb C++ API  Version 6.2.0.3
gpudb::AggregateUniqueResponse Struct Reference

A set of output parameters for aggregateUnique(const AggregateUniqueRequest&) const. More...

#include <gpudb/protocol/aggregate_unique.h>

Public Member Functions

 AggregateUniqueResponse ()
 Constructs an AggregateUniqueResponse object with default parameter values. More...
 

Public Attributes

std::string tableName
 
std::string responseSchemaStr
 
std::vector< gpudb::GenericRecorddata
 
bool hasMoreRecords
 
gpudb_type_ptr_t dataTypePtr
 

Detailed Description

A set of output parameters for aggregateUnique(const AggregateUniqueRequest&) const.

Returns all the unique values from a particular column (specified by columnName) of a particular table or collection (specified by tableName). If columnName is a numeric column the values will be in binaryEncodedResponse. Otherwise if columnName is a string column the values will be in jsonEncodedResponse. The results can be paged via the offset and limit parameters.

Columns marked as store-only are unable to be used with this function.

To get the first 10 unique values sorted in descending order options would be::

{"limit":"10","sort_order":"descending"}.

The response is returned as a dynamic schema. For details see: dynamic schemas documentation.

If a result_table name is specified in the options, the results are stored in a new table with that name–no results are returned in the response. Both the table name and resulting column name must adhere to standard naming conventions; any column expression will need to be aliased. If the source table's shard key is used as the columnName, the result table will be sharded, in all other cases it will be replicated. Sorting will properly function only if the result table is replicated or if there is only one processing node and should not be relied upon in other cases. Not available if tableName is a collection or when the value of columnName is an unrestricted-length string.

Definition at line 539 of file aggregate_unique.h.

Constructor & Destructor Documentation

◆ AggregateUniqueResponse()

gpudb::AggregateUniqueResponse::AggregateUniqueResponse ( )
inline

Constructs an AggregateUniqueResponse object with default parameter values.

Definition at line 546 of file aggregate_unique.h.

Member Data Documentation

◆ data

std::vector<gpudb::GenericRecord> gpudb::AggregateUniqueResponse::data

Definition at line 557 of file aggregate_unique.h.

◆ dataTypePtr

gpudb_type_ptr_t gpudb::AggregateUniqueResponse::dataTypePtr

Definition at line 559 of file aggregate_unique.h.

◆ hasMoreRecords

bool gpudb::AggregateUniqueResponse::hasMoreRecords

Definition at line 558 of file aggregate_unique.h.

◆ responseSchemaStr

std::string gpudb::AggregateUniqueResponse::responseSchemaStr

Definition at line 556 of file aggregate_unique.h.

◆ tableName

std::string gpudb::AggregateUniqueResponse::tableName

Definition at line 555 of file aggregate_unique.h.


The documentation for this struct was generated from the following file: