ExamGecko
Question list
Search
Search

Question 31 - AD0-E717 discussion

Report
Export

How should a record be removed from a database which is using a model that was inherited from the \Magento\Framework\Model\AbstractModel class?

A.
Call the 'unset' method on this model object
Answers
A.
Call the 'unset' method on this model object
B.
Call the 'remove' method on this model object
Answers
B.
Call the 'remove' method on this model object
C.
Call the 'delete' method on this model object
Answers
C.
Call the 'delete' method on this model object
Suggested answer: C

Explanation:

The 'delete' method on the \Magento\Framework\Model\AbstractModel class is used to remove a record from the database. This method will also cascade the delete to any related records.

asked 02/10/2024
Maxime ESSIS
38 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first