Ruby on Rails: pluck x select x map

Flavio Wuensche
5 min readJan 30, 2023

I’m writing this short article to clarify a few questions about Active Record vs Ruby methods to manipulate data coming from the database.

I'll start with some straightforward cases. Let's suppose you're looking for a list of emails from our user accounts. There are several ways you can achieve the same outcome. We'll start with the pluck method.

About :pluck, from Active…

--

--

Flavio Wuensche

Building an open-source tool to keep track of technical debt on large codebases 🍒 cherrypush.com