title: Increment id and assign it to string using ioredis for redis database
body: <p>I work on a blog using redis and I got stuck at the api level.
  I'm trying to do the following thing:</p>
  
  <pre><code>MULTI
  INCR id
  SET post:{id} json_value //Stucked here
  SADD posts {id}
  EXEC
  </code></pre>
  
  <p>So how do I get the id for the SET post:{id}?</p>
  
  <p>I have the following code for now which doesn't work yet.</p>
  
  <pre><code>// Create post
  function cpost(json) {
      client.pipeline()
          .incr('id'))
          .set('post:' + client.get('id:post', function (err, results) {
              return results;
          }), json)
          .sadd('posts, client.get('id:post', function (err, results) {
              return results;
          })) // posts post
          .exec(function (err, results) {
  
      });
  }
  </code></pre>
  
  <p>Using <a href="https://github.com/luin/ioredis" rel="nofollow">ioredis</a></p>
  
  <p>Any ideas on how to get the value of the id? </p>