数据库之MongoDB入门知识—关系型数据库与mongodb对比

存储方式对比

     在传统的关系型数据库中,存储方式是以的形式存放,而在MongoDB中,以文档的形式存在。

      数据库之MongoDB入门知识—关系型数据库与mongodb对比_第1张图片

   数据库中的对应关系,及存储形式的说明

        数据库之MongoDB入门知识—关系型数据库与mongodb对比_第2张图片

 MongoDB与SQL的结构对比详解

SQL Terms/Concepts MongoDB Terms/Concepts
database database
table

collection

row document or BSON document
column field
index index
table joins embedded documents and linking

primary key

Specify any unique column or

column combination as

primary key.

primary key

In MongoDB, the primary key is

automatically set to the _id field.

aggregation (e.g. group by)

aggregation pipeline

See the SQL to Aggregation Mapping

Chart.

 

基本的命令对比:

å¨è¿éæå¥å¾çæè¿°

你可能感兴趣的:(数据库之MongoDB入门知识—关系型数据库与mongodb对比)