Transformation: Sort Data
Learn about sorting the original data.
We'll cover the following...
Sort the data
Let’s have a look at the original design in the following figure.
We’re making good progress. We’ve coded all the functions of the top conveyor belt. Our next transformation is to sort the data on its created_at
field, with the newest entries first. And this can just use a standard Elixir library function, sort/2
. We could create a new module for this, but it would be pretty lonely. For now we’ll put the function in the CLI
module and keep an eye out for opportunities to move ...