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

267
Views
Sequelize returning null values from database (API problem)

I seem to have a problem with Sequelize . The thing is i have set an SQL database , when i try to reach it via sequelize (node) it just returns nulled values


[
    {
        "id": null
    },
    {
        "id": null
    },
    {
        "id": null
    },
    {
        "id": null
    },
    {
        "id": null
    },
    {
        "id": null
    },
    {
        "id": null
    },
    {
        "id": null
    },
    {
        "id": null
    },
    {
        "id": null
    },
    {
        "id": null
    }
]

This is my service, When i create an object inside the findUsers function and return as if it is real data , it just works


const User = require('../models/User');


const addUser = async (user) => {
  try {

    await User.create(user)
  } catch (e) {
    console.log(e);
  }
}

const findUsers = async () => {
  try {
    //return await User.findAll({});
    const u =   User.findAll();
    /*u = {
      nom : "lozo",
    }*/
    return u;
  } catch (e) {
        console.log(e)
  }
}
module.exports = {addUser,findUsers}
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!