Module: ActiveRecord::ConnectionAdapters::Savepoints
- Included in:
- AbstractMysqlAdapter, PostgreSQLAdapter, SQLite3Adapter
- Defined in:
- lib/active_record/connection_adapters/abstract/savepoints.rb
Overview
:nodoc:
Instance Method Summary collapse
- #create_savepoint(name = current_savepoint_name) ⇒ Object
- #release_savepoint(name = current_savepoint_name) ⇒ Object
- #rollback_to_savepoint(name = current_savepoint_name) ⇒ Object
- #supports_savepoints? ⇒ Boolean
Instance Method Details
#create_savepoint(name = current_savepoint_name) ⇒ Object
8 9 10 |
# File 'lib/active_record/connection_adapters/abstract/savepoints.rb', line 8 def create_savepoint(name = current_savepoint_name) execute("SAVEPOINT #{name}") end |
#release_savepoint(name = current_savepoint_name) ⇒ Object
16 17 18 |
# File 'lib/active_record/connection_adapters/abstract/savepoints.rb', line 16 def release_savepoint(name = current_savepoint_name) execute("RELEASE SAVEPOINT #{name}") end |
#rollback_to_savepoint(name = current_savepoint_name) ⇒ Object
12 13 14 |
# File 'lib/active_record/connection_adapters/abstract/savepoints.rb', line 12 def rollback_to_savepoint(name = current_savepoint_name) execute("ROLLBACK TO SAVEPOINT #{name}") end |
#supports_savepoints? ⇒ Boolean
4 5 6 |
# File 'lib/active_record/connection_adapters/abstract/savepoints.rb', line 4 def supports_savepoints? true end |