Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Fetches the temporarily cached result of an SQL statement. A token is returned to page through the statement results.
This operation returns paginated results.
Synopsis
- data GetStatementResult = GetStatementResult' {}
- newGetStatementResult :: Text -> GetStatementResult
- getStatementResult_nextToken :: Lens' GetStatementResult (Maybe Text)
- getStatementResult_id :: Lens' GetStatementResult Text
- data GetStatementResultResponse = GetStatementResultResponse' {
- totalNumRows :: Maybe Integer
- nextToken :: Maybe Text
- columnMetadata :: Maybe [ColumnMetadata]
- httpStatus :: Int
- records :: [[Field]]
- newGetStatementResultResponse :: Int -> GetStatementResultResponse
- getStatementResultResponse_totalNumRows :: Lens' GetStatementResultResponse (Maybe Integer)
- getStatementResultResponse_nextToken :: Lens' GetStatementResultResponse (Maybe Text)
- getStatementResultResponse_columnMetadata :: Lens' GetStatementResultResponse (Maybe [ColumnMetadata])
- getStatementResultResponse_httpStatus :: Lens' GetStatementResultResponse Int
- getStatementResultResponse_records :: Lens' GetStatementResultResponse [[Field]]
Creating a Request
data GetStatementResult Source #
See: newGetStatementResult
smart constructor.
GetStatementResult' | |
|
Instances
newGetStatementResult Source #
Create a value of GetStatementResult
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:nextToken:GetStatementResult'
, getStatementResult_nextToken
- A value that indicates the starting point for the next set of response
records in a subsequent request. If a value is returned in a response,
you can retrieve the next set of records by providing this returned
NextToken value in the next NextToken parameter and retrying the
command. If the NextToken field is empty, all response records have been
retrieved for the request.
$sel:id:GetStatementResult'
, getStatementResult_id
- The identifier of the SQL statement whose results are to be fetched.
This value is a universally unique identifier (UUID) generated by Amazon
Redshift Data API. A suffix indicates then number of the SQL statement.
For example, d9b6c0c9-0747-4bf4-b142-e8883122f766:2
has a suffix of
:2
that indicates the second SQL statement of a batch query. This
identifier is returned by BatchExecuteStatment
, ExecuteStatment
, and
ListStatements
.
Request Lenses
getStatementResult_nextToken :: Lens' GetStatementResult (Maybe Text) Source #
A value that indicates the starting point for the next set of response records in a subsequent request. If a value is returned in a response, you can retrieve the next set of records by providing this returned NextToken value in the next NextToken parameter and retrying the command. If the NextToken field is empty, all response records have been retrieved for the request.
getStatementResult_id :: Lens' GetStatementResult Text Source #
The identifier of the SQL statement whose results are to be fetched.
This value is a universally unique identifier (UUID) generated by Amazon
Redshift Data API. A suffix indicates then number of the SQL statement.
For example, d9b6c0c9-0747-4bf4-b142-e8883122f766:2
has a suffix of
:2
that indicates the second SQL statement of a batch query. This
identifier is returned by BatchExecuteStatment
, ExecuteStatment
, and
ListStatements
.
Destructuring the Response
data GetStatementResultResponse Source #
See: newGetStatementResultResponse
smart constructor.
GetStatementResultResponse' | |
|
Instances
newGetStatementResultResponse Source #
Create a value of GetStatementResultResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:totalNumRows:GetStatementResultResponse'
, getStatementResultResponse_totalNumRows
- The total number of rows in the result set returned from a query. You
can use this number to estimate the number of calls to the
GetStatementResult
operation needed to page through the results.
$sel:nextToken:GetStatementResult'
, getStatementResultResponse_nextToken
- A value that indicates the starting point for the next set of response
records in a subsequent request. If a value is returned in a response,
you can retrieve the next set of records by providing this returned
NextToken value in the next NextToken parameter and retrying the
command. If the NextToken field is empty, all response records have been
retrieved for the request.
$sel:columnMetadata:GetStatementResultResponse'
, getStatementResultResponse_columnMetadata
- The properties (metadata) of a column.
$sel:httpStatus:GetStatementResultResponse'
, getStatementResultResponse_httpStatus
- The response's http status code.
$sel:records:GetStatementResultResponse'
, getStatementResultResponse_records
- The results of the SQL statement.
Response Lenses
getStatementResultResponse_totalNumRows :: Lens' GetStatementResultResponse (Maybe Integer) Source #
The total number of rows in the result set returned from a query. You
can use this number to estimate the number of calls to the
GetStatementResult
operation needed to page through the results.
getStatementResultResponse_nextToken :: Lens' GetStatementResultResponse (Maybe Text) Source #
A value that indicates the starting point for the next set of response records in a subsequent request. If a value is returned in a response, you can retrieve the next set of records by providing this returned NextToken value in the next NextToken parameter and retrying the command. If the NextToken field is empty, all response records have been retrieved for the request.
getStatementResultResponse_columnMetadata :: Lens' GetStatementResultResponse (Maybe [ColumnMetadata]) Source #
The properties (metadata) of a column.
getStatementResultResponse_httpStatus :: Lens' GetStatementResultResponse Int Source #
The response's http status code.
getStatementResultResponse_records :: Lens' GetStatementResultResponse [[Field]] Source #
The results of the SQL statement.