Popular Activerecord Programming Tips
How to define fabricators of models with polymorphic associations
Alex Popov
·
0 responses
·
rails, activerecord, gem, assocations
Avoid ActiveRecord "Unknown column 'table.column' in 'field list'" exception between dropping the column and application restart
Tomasz Werbicki
·
0 responses
·
rails, activerecord, migration, database
Lottery Drawing SQL, Rails scope :)
George
·
0 responses
·
activerecord, sql, schema, db
Accessing ActiveRecord DB column options
Bill Agee
·
0 responses
·
ruby, rails, activerecord
Wrap multiple requests in one transaction
yanhaoyang
·
1 response
·
activerecord, rails, transaction
Add ActiveRecord scopes to Ctags
Ara
·
0 responses
·
rails, activerecord, ctags
Random record for all ActiveRecord model.
gobert
·
1 response
·
ruby, rails, activerecord
Rails N+1 with nested has_many
Bryan Mikaelian
·
0 responses
·
ruby, rails, activerecord
dynamically remove default_scope from ActiveRecord models when using Devise
Chris D'Aloisio
·
0 responses
·
rails, activerecord, devise, default_scope
Testing your AR models made easy with accepts_values_for
Oscar Rieken
·
2 responses
·
activerecord, testing, rspec
ActiveRecord search within a concatenation of to fields using an incomplete query
toni
·
0 responses
·
ruby, rails, activerecord, sql
Manipulating the database with ActiveRecord
Tomas Varneckas
·
0 responses
·
ruby, activerecord, schema
second to fifth methods for ActiveRecord Model
Rashmi
·
2 responses
·
rails, activerecord, rashmi14yadav
Never use ActiveRecord's last
Peter Boling
·
0 responses
·
rails, activerecord, last, explosions
Split ActiveRecord results based on a condition!
yaojie
·
0 responses
·
ruby, rails, activerecord
Using ActiveRecord in non-Rails projects in Rubymine
Michael Parks
·
0 responses
·
ruby, activerecord, ide, rubymine
Complex Has Many Associations with ActiveRecord
Sakchai Siripanyawuth
·
0 responses
·
rails, activerecord, database, query
Easily determining ownership in Rails
Josh McMillan
·
0 responses
·
ruby, rails, activerecord, ownership
ActiveRecord get all ids
Jeremy Bertrand
·
0 responses
·
rails, activerecord, populator
Check the last inserted record with Cucumber
Fabrizio Soppelsa
·
0 responses
·
ruby, activerecord, cucumber, rspec
Reusing SQL logic in Rails models
Wojtek Kruszewski
·
0 responses
·
rails, activerecord, wojt-eu
Easily add named timestamp scopes
Jake Moffatt
·
0 responses
·
rails, activerecord, gem, scopes
Limitless strings for Postgresql
Robbie Marcelo
·
0 responses
·
activerecord, rails, postgresql
Use :symbol.gt in ActiveRecord
Davide D'Agostino
·
0 responses
·
ruby, activerecord, rails
Use schema_validations to make your ActiveRecord classes more DRY
Diogo Biazus
·
0 responses
·
rails, activerecord, database, postgresql
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#
Coderwall Dev Community
Explore the all-time favorite tutorials, design patterns and engineering guides that thousands of readers keep sharing and coming back to, year after year.
These proven techniques, reusable code samples, programming tips and vibe coding habits earned their place through steady views and member likes.
Each entry here is still useful today, covering programming languages, frameworks and workflows that stay relevant long after they were first published.
Whether you're new to a tech stack or an experienced engineer refreshing your skills, start with the most useful tips our dev community members recommend and build on solid, well-tested coding knowledge.