I am trying to implement a GraphQL server that uses Sequelize in the back-end (for working with MSSQL backstage). And I have a query that works fine (retrieving data from a single SQL table), as expected.
But then I set up the mutation for the same circuit, and when I ran the mutation in GraphiQL, I found that although it does work inside the mutation resolution function (which is to instantiate my Sequelize circuit), it does not return my object to me .

Now I understand this because my Sequelize function .createreturns a promise, and the solution can't handle it?
Here is what I have so far:
resolve(_,args){
Forecast.create({
bunit: args.bunit,
season: args.season,
position: args.position,
currency: args.currency,
settle_date: new Date(args.settle_date),
reference: args.reference
}).then(forecast => {
return forecast;
}).catch(err => {
console.error(err);
return err;
});
}
, , , , - . , .