官术网_书友最值得收藏!

Modeling objects without SQL

A classic paradox in object oriented programming (OOP) code that requires database access is caused by the two-dimensional architecture of the traditional RDBMS. The two dimensions, rows and columns, are in turn grouped into tables, much like a legacy spreadsheet. In order to achieve the third dimension one needs to perform resource intensive joins and form relationships between tables. In order to map programming object classes to the database, incredible programmatic gymnastics are required to achieve the goal.

With MongoDB, there is no rigid database schema you must adhere to. Instead of rows you insert documents. A set of documents is referred to as a collection. Each document can directly model an object class, which in turn greatly facilitates the work of storing and retrieving from the database.

MongoDB has its own rich query language, which can perform tasks similar to what the developer might expect from a legacy RDBMS using SQL. Because MongoDB does not use SQL, it is often referred to as a NoSQL database.

For an excellent introduction to NoSQL, its underlying philosophy and its ramifications, a highly recommended resource can be found in the NoSQL Guide ( https://martinfowler.com/nosql.html) on Martin Fowler's website.
主站蜘蛛池模板: 肇源县| 沈阳市| 锦屏县| 都江堰市| 三门峡市| 柳河县| 皋兰县| 吉水县| 聂拉木县| 宁明县| 友谊县| 石渠县| 大名县| 滁州市| 道孚县| 德格县| 崇州市| 宜兰县| 房山区| 虹口区| 安平县| 北票市| 东丰县| 鹤壁市| 南川市| 名山县| 双流县| 建阳市| 哈尔滨市| 普兰店市| 五家渠市| 黑水县| 通化县| 威远县| 南昌县| 太白县| 固镇县| 保德县| 曲麻莱县| 秭归县| 吉水县|