Pages
    • GETTING STARTED
        • API REFERENCE
                                                                                                                                              • COMMAND LINE
                                                                                                                                                  On this page

                                                                                                                                                      .commit()

                                                                                                                                                      The transaction.commit() method.

                                                                                                                                                      This method is used to commit up to a savepoint in a transaction. It is used to certify that all records up to the specified savepoint are permanent changes.

                                                                                                                                                      Syntax

                                                                                                                                                      transaction.commit(savepoint = 0);
                                                                                                                                                      • savepoint: Int - The savepoint to commit up to. 0 refers to the record of the first call to .savepoint(); 1 to the second call; and so on.

                                                                                                                                                      Return

                                                                                                                                                      Usage

                                                                                                                                                      Obtain an instance of an ongoing transaction and call .commit(). Below, we build on the usage example on the Transaction page. Here we use the .commit() method to commit all savepoints. Calling the transaction's .rollback() method after this point will have no effect.

                                                                                                                                                      ananimationi.commit(0);