| Start |
|---|
| Getting Started with Active Record Transactions Active Record Transactions can be applied to Model classes as well as Model instances, the objects within the transaction block need not all be instances of same class. This is because transactions are per-database connection, not per-model. For example: Using save with a bang ensures that transaction will be automatically rolled back when the exception is thrown and after the rollback, control goes to the rescue block for the exception. Make sure you rescue the exceptions thrown from the save! in Transaction Block. If you don't want to use save!, you can manually raise |
| Getting Started with Active Record Transactions Active Record Transactions can be applied to Model classes as well as Model instances, the objects within the transaction block need not all be instances of same class. This is because transactions are per-database connection, not per-model. For example: Using save with a bang ensures that transaction will be automatically rolled back when the exception is thrown and after the rollback, control goes to the rescue block for the exception. Make sure you rescue the exceptions thrown from the save! in Transaction Block. If you don't want to use save!, you can manually raise |
| Getting Started with Active Record Transactions Active Record Transactions can be applied to Model classes as well as Model instances, the objects within the transaction block need not all be instances of same class. This is because transactions are per-database connection, not per-model. For example: Using save with a bang ensures that transaction will be automatically rolled back when the exception is thrown and after the rollback, control goes to the rescue block for the exception. Make sure you rescue the exceptions thrown from the save! in Transaction Block. If you don't want to use save!, you can manually raise |
| Getting Started with Active Record Transactions Active Record Transactions can be applied to Model classes as well as Model instances, the objects within the transaction block need not all be instances of same class. This is because transactions are per-database connection, not per-model. For example: Using save with a bang ensures that transaction will be automatically rolled back when the exception is thrown and after the rollback, control goes to the rescue block for the exception. Make sure you rescue the exceptions thrown from the save! in Transaction Block. If you don't want to use save!, you can manually raise |
Read Article
https://develop.horje.com/learn/1434/reference