Skip to content

Instantly share code, notes, and snippets.

@Fernan2
Last active January 17, 2017 19:40
Show Gist options
  • Save Fernan2/1c4782c18bedd2ff51fc326a59b7b6ff to your computer and use it in GitHub Desktop.
Save Fernan2/1c4782c18bedd2ff51fc326a59b7b6ff to your computer and use it in GitHub Desktop.
Enumerados en Rails y Postgres 4
Prestamo.where(finalidad: 'Estudios').count
@prestamo.update_attribute(:finalidad, 'Estudios')
@prestamo.finalidad == 'Estudios'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment