Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

214
Views
Firebase function only loading on node pgsql query

I am just started learning node js. I am trying to host a firebase function. But when I query database (PGSQL using node pg) I am getting forever loading. Please see my code..

exports.myfunction = async(req, res) => {
  const {Client} = require('pg');
  const client = new Client({
    user: "dfgdfgdfg",
    host: "IP Address given",
    database: "sdfdsfsd",
    password: "fsdfdsf",
    port: "54321",
  });

 

// res.send('hi'); works fine here

    const rest = await client.query("SELECT id,unique_withdraw_id,asset_id,amount,address FROM withdrawals WHERE transfer_network = $1 AND status=$2 LIMIT $3",
    ['ETH', 'Accepted', 20]);


// res.send('hi'); does not work here, the browser keeps loading...

}
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!