GPUdb C++ API  Version 5.2.0.0
gpudb::GetRecordsByColumnRequest Struct Reference

A set of input parameters for getRecordsByColumnRaw(const GetRecordsByColumnRequest&) const. More...

#include <gpudb/protocol/get_records_by_column.h>

Public Member Functions

 GetRecordsByColumnRequest ()
 Constructs a GetRecordsByColumnRequest object with default parameter values. More...
 
 GetRecordsByColumnRequest (const std::string &tableName, const std::vector< std::string > &columnNames, const int64_t offset, const int64_t limit, const std::map< std::string, std::string > &options)
 Constructs a GetRecordsByColumnRequest object with the specified parameters. More...
 
 GetRecordsByColumnRequest (const std::string &tableName, const std::vector< std::string > &columnNames, const int64_t offset, const int64_t limit, const std::string &encoding, const std::map< std::string, std::string > &options)
 Constructs a GetRecordsByColumnRequest object with the specified parameters. More...
 

Public Attributes

std::string tableName
 
std::vector< std::string > columnNames
 
int64_t offset
 
int64_t limit
 
std::string encoding
 
std::map< std::string, std::string > options
 

Detailed Description

A set of input parameters for getRecordsByColumnRaw(const GetRecordsByColumnRequest&) const.

For a given table, retrieves the values of the given columns within a given range. It returns maps of column name to the vector of values for each supported data type (double, float, long, int and string). This operation supports pagination feature, i.e. values that are retrieved are those associated with the indices between the start (offset) and end value (offset + limit) parameters (inclusive). If there are num_points values in the table then each of the indices between 0 and num_points-1 retrieves a unique value.

Note that when using the pagination feature, if the table (or the underlying table in case of a view) is updated (records are inserted, deleted or modified) the records or values retrieved may differ between calls (discontiguous or overlap) based on the type of the update.

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

Definition at line 36 of file get_records_by_column.h.

Constructor & Destructor Documentation

gpudb::GetRecordsByColumnRequest::GetRecordsByColumnRequest ( )
inline

Constructs a GetRecordsByColumnRequest object with default parameter values.

Definition at line 43 of file get_records_by_column.h.

gpudb::GetRecordsByColumnRequest::GetRecordsByColumnRequest ( const std::string &  tableName,
const std::vector< std::string > &  columnNames,
const int64_t  offset,
const int64_t  limit,
const std::map< std::string, std::string > &  options 
)
inline

Constructs a GetRecordsByColumnRequest object with the specified parameters.

Parameters
[in]tableNameName of the table on which this operation will be performed. The table cannot be a parent set.
[in]columnNamesThe list of column values to retrieve. Columns annotated as store only cannot be retrieved.
[in]offsetA positive integer indicating the number of initial results to skip (this can be useful for paging through the results). The minimum allowed value is 0. The maximum allowed value is MAX_INT.
[in]limitA positive integer indicating the maximum number of results to be returned (if not provided the default is 10000). Or END_OF_column (-9999) to indicate that the max number of results should be returned.
[in]options
  • expression: Optional filter expression to apply to the table.
  • sort_by: Optional column that the data should be sorted by. Empty by default (i.e. no sorting is applied).
  • sort_order: String indicating how the returned values should be sorted - ascending or descending. Default is 'ascending'. Ignored if 'sort_by' option is not specified. Values: 'ascending', 'descending'.
Default value is an empty std::map.

Definition at line 88 of file get_records_by_column.h.

gpudb::GetRecordsByColumnRequest::GetRecordsByColumnRequest ( const std::string &  tableName,
const std::vector< std::string > &  columnNames,
const int64_t  offset,
const int64_t  limit,
const std::string &  encoding,
const std::map< std::string, std::string > &  options 
)
inline

Constructs a GetRecordsByColumnRequest object with the specified parameters.

Parameters
[in]tableNameName of the table on which this operation will be performed. The table cannot be a parent set.
[in]columnNamesThe list of column values to retrieve. Columns annotated as store only cannot be retrieved.
[in]offsetA positive integer indicating the number of initial results to skip (this can be useful for paging through the results). The minimum allowed value is 0. The maximum allowed value is MAX_INT.
[in]limitA positive integer indicating the maximum number of results to be returned (if not provided the default is 10000). Or END_OF_column (-9999) to indicate that the max number of results should be returned.
[in]encodingSpecifies the encoding for returned records; either 'binary' or 'json'. Values: 'binary', 'json'. Default value is 'binary'.
[in]options
  • expression: Optional filter expression to apply to the table.
  • sort_by: Optional column that the data should be sorted by. Empty by default (i.e. no sorting is applied).
  • sort_order: String indicating how the returned values should be sorted - ascending or descending. Default is 'ascending'. Ignored if 'sort_by' option is not specified. Values: 'ascending', 'descending'.
Default value is an empty std::map.

Definition at line 137 of file get_records_by_column.h.

Member Data Documentation

std::vector<std::string> gpudb::GetRecordsByColumnRequest::columnNames

Definition at line 148 of file get_records_by_column.h.

std::string gpudb::GetRecordsByColumnRequest::encoding

Definition at line 151 of file get_records_by_column.h.

int64_t gpudb::GetRecordsByColumnRequest::limit

Definition at line 150 of file get_records_by_column.h.

int64_t gpudb::GetRecordsByColumnRequest::offset

Definition at line 149 of file get_records_by_column.h.

std::map<std::string, std::string> gpudb::GetRecordsByColumnRequest::options

Definition at line 152 of file get_records_by_column.h.

std::string gpudb::GetRecordsByColumnRequest::tableName

Definition at line 147 of file get_records_by_column.h.


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