title: the best way to exclude some data from a method in sails controller
body: <p>I want's to exclude some data in some controller method and in other method i want's that data. I do it with <code>forEach</code> function right into method after finding that  :</p>
  
  <pre><code>nine: function (req, res) {
      Dore.find()
          .limit(9)
          .sort('createdAt DESC')
          .populate('file')
          .exec(function (err, sh) {
              if (err) {
                  return res.negotiate(err);
              } else {
                  console.log('before : ', sh);
                  sh.forEach(function (item, i) {
                      delete item.zaman;
                  });
                  console.log('after : ', sh);
                  return res.send(sh);
              }
          });
  },
  </code></pre>
  
  <p>I want to know how possible to do that with finding and do not included ever in finding so we don't need to remove that again with <code>forEach</code>.
  tanks</p>
  
  <p>As @zabware say we have <code>select</code> method in <code>Query option</code> I try this format but do not work and return all data :</p>
  
  <p>I try to use that with following format but don't working :</p>
  
  <pre><code>Model.find( {
              where: {},
              limit: 9,
              sort: 'createdAt DESC'
          },
          {
              select: [ 'id', 'createdAt' ]
          } )
  </code></pre>
  
  <p>and</p>
  
  <pre><code>Model.find( {
              where: {},
              limit: 9,
              sort: 'createdAt DESC',
                          select: [ 'id', 'createdAt' ]
          } )
  </code></pre>
  
  <p>and</p>
  
  <pre><code>Model.find( {}, select: [ 'id', 'createdAt' ] )
  </code></pre>