MongoDB Differentiates Between undefined vs. null

后端 未结 3 1135
旧巷少年郎
旧巷少年郎 2021-01-17 21:23

I was checking logic for querying on non-values and noticed when using the mongo shell, it differentiates between undefined and null v

3条回答
  •  花落未央
    2021-01-17 22:04

    In case you wonder, why MongoDB casts undefined to null instead of just ignoring such properties - ignoreUndefined flag could solve this behaviour.

    https://mongodb.github.io/node-mongodb-native/2.1/reference/connecting/connection-settings/

提交回复
热议问题