<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns="http://purl.org/rss/1.0/"
xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel rdf:about="https://dwt.life/feed/rss/tag/mongodb/">
<title>dwt&#039;s life - mongodb</title>
<link>https://dwt.life/tag/mongodb/</link>
<description></description>
<items>
<rdf:Seq>
<rdf:li resource="https://dwt.life/archives/191/"/>
</rdf:Seq>
</items>
</channel>
<item rdf:about="https://dwt.life/archives/191/">
<title>Mongdb非空数组查询</title>
<link>https://dwt.life/archives/191/</link>
<dc:date>2022-02-14T01:29:03+08:00</dc:date>
<description>db.idap_zl.insert({array:[]})db.idap_zl.insert({array:[1,2,3,4,5]})db.idap_zl.find({array:{$elemMatch:{$ne:null}}})一、elemMatch和elemMatch和nedb.Collection.find({array:{$elemMatch:{$ne:null}}})二、$wheredb.Collection.find({$where:&quot;this.array.length&gt;0&quot;})三、not和not和sizedb.Collection.find({array: {$not: {$size: 0}}})四、'.'路径和$existsdb.Collection.find({{&#039;array.0&#039;: {$exists: 1}}})五、exists和exists和nedb.Collection.find({ array: { $exists: true, $ne: [] } })六、$gtdb.Collection.find({ array: { $gt: [] } })</description>
</item>
</rdf:RDF>