Module org.apache.arrow.flight.sql
Package org.apache.arrow.flight.sql
Class FlightSqlClient.PreparedStatement
java.lang.Object
org.apache.arrow.flight.sql.FlightSqlClient.PreparedStatement
- All Implemented Interfaces:
- AutoCloseable
- Enclosing class:
- FlightSqlClient
Helper class to encapsulate Flight SQL prepared statement logic.
- 
Method SummaryModifier and TypeMethodDescriptionprotected final voidChecks whether this client is open.voidCloses theparameterBindingRoot, which contains the parameter binding from aFlightSqlClient.PreparedStatementoperation, releasing its resources.voidclose()voidclose(CallOption... options) Closes the client.execute(CallOption... options) Executes the prepared statement query on the server.longexecuteUpdate(CallOption... options) Executes the prepared statement update on the server.fetchSchema(CallOption... options) Get the schema of the result set (should be identical togetResultSetSchema()).Returns the Schema of the parameters.Returns the Schema of the resultset.booleanisClosed()Returns if the prepared statement is already closed.voidsetParameters(VectorSchemaRoot parameterBindingRoot) Set theparameterBindingRootcontaining the parameter binding from aFlightSqlClient.PreparedStatementoperation.
- 
Method Details- 
setParametersSet theparameterBindingRootcontaining the parameter binding from aFlightSqlClient.PreparedStatementoperation.- Parameters:
- parameterBindingRoot- a- VectorSchemaRootobject containing the values to be used in the- PreparedStatementsetters.
 
- 
clearParameterspublic void clearParameters()Closes theparameterBindingRoot, which contains the parameter binding from aFlightSqlClient.PreparedStatementoperation, releasing its resources.
- 
getResultSetSchemaReturns the Schema of the resultset.- Returns:
- the Schema of the resultset.
 
- 
getParameterSchemaReturns the Schema of the parameters.- Returns:
- the Schema of the parameters.
 
- 
fetchSchemaGet the schema of the result set (should be identical togetResultSetSchema()).
- 
executeExecutes the prepared statement query on the server.- Parameters:
- options- RPC-layer hints for this call.
- Returns:
- a FlightInfo object representing the stream(s) to fetch.
 
- 
checkOpenprotected final void checkOpen()Checks whether this client is open.- Throws:
- IllegalStateException- if client is closed.
 
- 
executeUpdateExecutes the prepared statement update on the server.- Parameters:
- options- RPC-layer hints for this call.
- Returns:
- the count of updated records
 
- 
closeCloses the client.- Parameters:
- options- RPC-layer hints for this call.
 
- 
closepublic void close()- Specified by:
- closein interface- AutoCloseable
 
- 
isClosedpublic boolean isClosed()Returns if the prepared statement is already closed.- Returns:
- true if the prepared statement is already closed.
 
 
-