No results found in makandra Operations.
Best results in other decks
...you don't have an ActiveRecord class in your scope, you can always use ActiveRecord::Base.transaction do...
By using a transaction we have grouped together the creation of the...
...a single database row, you should always use a transaction. Note that in Rails, ActiveRecord::Base#save automatically opens a transaction. Hence changes you make in callbacks, nested attributes processing...
...on database statements by default, the following query will run for an entire day: ActiveRecord::Base.connection.execute("SELECT pg_sleep(86400)") The good news is that with statement_timeout for PostgreSQL...
...adapter: postgresql # ... variables: statement_timeout: 10s # or ms, min, etc Test that it works: ActiveRecord::Base.connection.execute("show statement_timeout;").map { |row| row } => [{"statement_timeout"=>"10s"}] begin ActiveRecord::Base.connection.execute("SELECT pg...