News for hackers. Stuff that matters.
Re:How 'DevOps' Is Killing the Developer (2014) by krainboltgreene on Thursday June 28, 2018 @01:28PM (#17418844)
> I remember when foreign keys were taboo among Rails developers because Rails didn't have a way to express them in its DSL.

What? Relationships (and thus foreign keys) have been around since before 1.2.

Re:How 'DevOps' Is Killing the Developer (2014) by pmontra on Thursday June 28, 2018 @05:49PM (#17420779)
Relationships are not foreign keys. Relationships (has_many, belongs_to) are a Rails construct. Foreign keys are a database thing.

I started using Rails almost at the very beginning. See https://stackoverflow.com/questions/2373262/are-foreign-keys... from 2010 for a bunch of links to DHH opinion on the matter (from 2006.)

Foreign keys made it into the DSL with Rails 4.2

http://guides.rubyonrails.org/4_2_release_notes.html#foreign...

https://apidock.com/rails/ActiveRecord/ConnectionAdapters/Sc...

Before that we were using gems or writing SQL into the up and down migrations.

https://robots.thoughtbot.com/referential-integrity-with-for... (from December 2014)

Re:How 'DevOps' Is Killing the Developer (2014) by krainboltgreene on Tuesday July 03, 2018 @03:56AM (#17448318)
Just to be clear, you keep saying "foreign key", but the phrase most people know is "foreign key constraint" (because it's just a constraint).