Interface ResultSet
- All Known Implementing Classes:
ResultSetImpl
@PublicEvolving
public interface ResultSet
A
ResultSet represents the collection of the results. This interface defines the methods
that can be used on the ResultSet.-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumDescribe the kind of the result. -
Method Summary
Modifier and TypeMethodDescriptionList<org.apache.flink.table.data.RowData>getData()All the data in the current results.org.apache.flink.api.common.JobIDgetJobID()If the statement was submitted to a client, returns the JobID which uniquely identifies the job.The token indicates the next batch of the data.org.apache.flink.table.api.ResultKindGets the result kind of the result.org.apache.flink.table.catalog.ResolvedSchemaThe schema of the data.Get the type of the results, which may indicate the result is EOS or has data.booleanIndicates that whether the result is for a query.
-
Method Details
-
getResultType
ResultSet.ResultType getResultType()Get the type of the results, which may indicate the result is EOS or has data. -
getNextToken
The token indicates the next batch of the data.When the token is null, it means all the data has been fetched.
-
getResultSchema
org.apache.flink.table.catalog.ResolvedSchema getResultSchema()The schema of the data.The schema of the DDL, USE, EXPLAIN, SHOW and DESCRIBE align with the schema of the
TableResult.getResolvedSchema(). The only differences is the schema of the `INSERT` statement.The schema of INSERT:
+-------------+-------------+----------+ | column name | column type | comments | +-------------+-------------+----------+ | job id | string | | +- -----------+-------------+----------+
-
getData
List<org.apache.flink.table.data.RowData> getData()All the data in the current results. -
isQueryResult
boolean isQueryResult()Indicates that whether the result is for a query. -
getJobID
@Nullable org.apache.flink.api.common.JobID getJobID()If the statement was submitted to a client, returns the JobID which uniquely identifies the job. Otherwise, returns null. -
getResultKind
org.apache.flink.table.api.ResultKind getResultKind()Gets the result kind of the result.
-