Package com.exasol.adapter.request
Class PushDownRequest
- java.lang.Object
-
- com.exasol.adapter.request.AbstractAdapterRequest
-
- com.exasol.adapter.request.PushDownRequest
-
- All Implemented Interfaces:
AdapterRequest
public class PushDownRequest extends AbstractAdapterRequest
This class represents a request that tells a Virtual Schema Adapter to push a SQL statement down to the external data source.
-
-
Constructor Summary
Constructors Constructor Description PushDownRequest(SchemaMetadataInfo schemaMetadataInfo, SqlStatement select, List<TableMetadata> involvedTablesMetadata, List<DataType> selectListDataType)
Create a new request of typePushDownRequest
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
executeWith(AdapterCallExecutor adapterCallExecutor, com.exasol.ExaMetadata metadata)
Execute an adapter call.List<TableMetadata>
getInvolvedTablesMetadata()
Get the metadata for the tables involved in the pushdown operationSqlStatement
getSelect()
Get theSELECT
statement that should be pushed down to the external data source.List<DataType>
getSelectListDataTypes()
Get the expected data types for the result set.-
Methods inherited from class com.exasol.adapter.request.AbstractAdapterRequest
getSchemaMetadataInfo, getType, getVirtualSchemaName, toString
-
-
-
-
Constructor Detail
-
PushDownRequest
public PushDownRequest(SchemaMetadataInfo schemaMetadataInfo, SqlStatement select, List<TableMetadata> involvedTablesMetadata, List<DataType> selectListDataType)
Create a new request of typePushDownRequest
.- Parameters:
schemaMetadataInfo
- schema metadataselect
- SQL statement to be pushed down to the external data sourceinvolvedTablesMetadata
- tables involved in the push-down requestselectListDataType
- expected data types for the result set
-
-
Method Detail
-
getSelect
public SqlStatement getSelect()
Get theSELECT
statement that should be pushed down to the external data source.- Returns:
SELECT
statement
-
getInvolvedTablesMetadata
public List<TableMetadata> getInvolvedTablesMetadata()
Get the metadata for the tables involved in the pushdown operation- Returns:
- metadata of involved tables
-
getSelectListDataTypes
public List<DataType> getSelectListDataTypes()
Get the expected data types for the result set.- Returns:
- expected data types for the result set
-
executeWith
public String executeWith(AdapterCallExecutor adapterCallExecutor, com.exasol.ExaMetadata metadata) throws AdapterException
Description copied from interface:AdapterRequest
Execute an adapter call.- Parameters:
adapterCallExecutor
- instance ofAdapterCallExecutor
metadata
- metadata for the context in which the adapter exists- Returns:
- response in a JSON format
- Throws:
AdapterException
- if some problem occurs
-
-