Content deleted Content added
Thanks for your suggestions |
m v2.04b - Bot T20 CW#61 - Fix errors for CW project (Reference before punctuation) |
||
Line 1:
In [[software engineering]], the '''active record pattern''' is considered an [[Architectural pattern (computer science)|architectural pattern]] by some people and as an [[anti-pattern]] by some others recently.<ref>[https://www.oreilly.com/library/view/sql-antipatterns/9781680500073/f_0159.html Antipattern: The Model Is an Active Record]</ref><ref>[https://www.mehdi-khalili.com/orm-anti-patterns-part-1-active-record ORM anti-patterns - Part 1: Active Record]</ref>
The active record pattern is an approach to accessing data in a [[database]]. A [[database table]] or [[View (database)|view]] is wrapped into a [[class (computer science)|class]]. Thus, an [[object (computer science)|object]] instance is tied to a single row in the table. After creation of an object, a new row is added to the table upon save. Any object loaded gets its information from the database. When an object is updated, the corresponding row in the table is also updated. The wrapper class implements [[accessor]] [[Method (computer programming)|methods]] or properties for each column in the table or view.
|