node-simple-odata-server icon indicating copy to clipboard operation
node-simple-odata-server copied to clipboard

Defect(?): Need sample for use with Mongodb

Open lboening opened this issue 7 years ago • 4 comments

I am bit puzzled. I cannot get a sample to work

I can get the plain sample to work. The next one, I cannot. Can you check the Gist?

Mongodb

  • Host: localhost:27017
  • Database: jsreport
  • Collection: jsreport
  • Authentication: none

Here's what I got. I must have set something wrong Gist

lboening avatar Feb 20 '18 19:02 lboening

This gist works for me if I change line

var odataServer = ODataServer('http://localhost:1338').model(model);

pofider avatar Feb 20 '18 19:02 pofider

I have made progress, but now I am blocked. The mongodb client does not get anything from my link to a Mongodb at Atlas cluster. Would you be able to check my syntax? Link to Gist

Question: can the Mongoclient handle a URL to Atlas? Link to Atlas docs

lboening avatar Feb 22 '18 00:02 lboening

Sure it can connect to atlas. However this is not related to this package and I keep it up to you to find out how.

pofider avatar Feb 22 '18 08:02 pofider

Hello pofider, i am also need a sample for mongodb, i dont know how to modify the simple.js file to suit mongodb.Thanks.

emasjin avatar Aug 15 '19 07:08 emasjin