title: how to save the array in mongodb by using node.js
body: <pre><code>{
      &quot;_id&quot; :
      &quot;statinaryId&quot;:&quot;01&quot;,
      &quot;booktype&quot;:[
              {
                  &quot;BookId&quot;:&quot;01&quot;,
                  &quot;smallBook&quot;: &quot;book1&quot;,
                  &quot;plainBook&quot;: &quot;book1&quot;,
                  &quot;ruledBook&quot;: &quot;book1&quot;,
                  &quot;longBook&quot;: &quot;book1&quot;
              }
           ]
                   
      &quot;pens&quot;: [
          {
              &quot;Penid&quot;: &quot;01&quot;,
              &quot;gelpen&quot;: &quot;pen1&quot;,
              &quot;griperpen&quot;: &quot;pen1&quot;,
              &quot;colorpen&quot;:&quot;pen1&quot;
          }
      ]
     &quot;pencils&quot;: [
           {
              &quot;pencilid&quot;: &quot;01&quot;,
              &quot;penpencil&quot;: &quot;penpencil1&quot;,
              &quot;colorpencil&quot;:&quot;pencil1&quot;
  
            }
       ]
  }
  </code></pre>