rdblue commented on a change in pull request #1217:
URL: https://github.com/apache/iceberg/pull/1217#discussion_r457662580
##########
File path: site/docs/api.md
##########
@@ -99,6 +99,8 @@ Available operations to update a table are:
### Transactions
+`Table` also enables to commit multiple table operations at once.
Review comment:
I think we should either remove this empty section or expand it a bit
beyond what you have here.
Transactions are used to commit multiple table changes in a single atomic
operation. A transaction is used to create individual operations using factory
methods, like `newAppend`, just like working with a `Table`. But operations
created by a transaction are committed as a group when `commitTransaction` is
called.
```java
Transaction t = table.newTrasaction();
// commit operations to the transaction
t.newDelete().deleteFromRowFilter(filter).commit();
t.newAppend().appendFile(data).commit();
// commit all the changes to the table
t.commitTransaction();
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]