Tell me what's the difference between destroy and delete?
Submitted by: MuhammadBoth of these methods delete the record in the database. The different between them is that:
☛ destroy – checks and deletes connected records if necessary and calls callbacks i.e. before_destroy, after_destroy etc.
☛ delete – doesn't call callbacks and removes an object directly from the database.
Submitted by: Muhammad
☛ destroy – checks and deletes connected records if necessary and calls callbacks i.e. before_destroy, after_destroy etc.
☛ delete – doesn't call callbacks and removes an object directly from the database.
Submitted by: Muhammad
Read Online Ruby on Rails Developer Job Interview Questions And Answers
Top Ruby on Rails Developer Questions
☺ | What is RVM? |
☺ | What is Rails Scaffolding? |
☺ | Explain me what Are The Components Defined In The Model From Mvc Architecture? |
☺ | Please explain request/response cycle? |
☺ | Explain what’s different between ActiveRecord::Relation’s count, length and size methods? |
Top Coding/Programming Categories
☺ | Python Interview Questions. |
☺ | OOP Interview Questions. |
☺ | Software engineering Interview Questions. |
☺ | PHP Interview Questions. |
☺ | VBA (Visual Basic for Applications) Interview Questions. |