title: Push data from aws lambda to redshift
body: <p>I am trying to create a Lambda function which will connect to RedShift :</p>
  
  <pre><code>var pg = require('pg');
  var conString = 'postgresql://username:Password@JDBC-URL';
  var client = new pg.Client(conString);
  client.connect(function(err) { if(err) {
          console.log('could not connect to redshift', err);
      }
      });
  pgClient.end();
  </code></pre>
  
  <p>But I am getting this exception :</p>
  
  <pre><code>Unable to import module 'index': Error 
  at Function.Module._resolve Filename (module.js:325:15) 
  at Function.Module._load (module.js:276:25) 
  at Module.require (module.js:353:17) 
  at require (internal/module.js:12:17) 
  at Object.&lt;anonymous&gt; (/var/task/index.js:1:72) 
  at Module._compile (module.js:409:26) 
  at Object.Module._extensions..js (module.js:416:10) 
  at Module.load (module.js:343:32) 
  at Function.Module._load (module.js:300:12) 
  at Module.require (module.js:353:17)
  </code></pre>
  
  <p>Can someone please help me with this.</p>
  
  <p>Thanks.</p>