Use a prepared ECSQL statement. This function takes care of preparing the statement and then releasing it.
As preparing statements can be costly, they get cached. When calling this method again with the same ECSQL, the already prepared statement from the cache will be reused.
withPreparedStatement<T>(ecsql: string, callback: (stmt: ECSqlStatement) => T): T
|ecsql||string||The ECSQL statement to execute|
|callback||(stmt: ECSqlStatement) => T||the callback to invoke on the prepared statement|
Returns - the value returned by cb
Last Updated: 08 January, 2020