Questions tagged [nedb]

Embedded persistent database for Node.js, written in Javascript, with no dependency (except npm modules of course). You can think of it as a SQLite for Node.js projects, which can be used with a simple `require` statement. The API is a subset of MongoDB's. You can use it as a persistent or an in-memory only datastore.

About

NeDB is not intended to be a replacement of large-scale databases such as MongoDB! Its goal is to provide you with a clean and easy way to query data and persist it to disk, for web applications that do not need lots of concurrent connections, for example a continuous integration and deployment server and desktop applications built with Node Webkit or Electron.

Links

195 questions
29
votes
5 answers

How can I get the path that the application is running with typescript?

I am trying to create a desktop application with electron, angular2, typescript and neDB.In order to be able create a 'file' database with neDB I want the path to my project.How can I get this with typescript ?
geo
  • 2,283
  • 5
  • 28
  • 46
12
votes
1 answer

Local, file-based database for an Electron application

We are working on an application that will be offered both as a web-based and as a cross-platform desktop solution by means of Electron. Due to customer requirements, the desktop client cannot make use of "the cloud" to store data; all data should…
Sergi Papaseit
  • 15,999
  • 16
  • 67
  • 101
7
votes
0 answers

NeDB regex operator called with non regular expression

I'm trying to search string using regex as below: db.find({ consignee: { $regex: /test/ } }, function (err, docs) { }); But it is throwing error Error: $regex operator called with non regular expression
Rohit
  • 2,987
  • 3
  • 25
  • 50
7
votes
2 answers

In need of an embeddable NoSQL database that handles ~1Gb datasets, persisted on disk

I am building an Electron app, for which I need to select an embeddable NoSQL database. In fact, this database is supposed to hold a local subset of data stored on an ArangoDB remote backend. I have been searching the Internet a lot, but fail so far…
Willem van Gerven
  • 1,407
  • 1
  • 17
  • 24
6
votes
1 answer

nedb method update and delete creates a new entry instead updating existing one

I'm using nedb and I'm trying to update an existing record by matching it's ID, and changing a title property. What happens is that a new record gets created, and the old one is still there. I've tried several combinations, and tried googling for…
Nemanja Milosavljevic
  • 1,251
  • 18
  • 33
5
votes
2 answers

Persist nedb to disk in Electron renderer process (Webpack/Electron/nedb configuration problem)

Problem I'm trying to use a pure-JS database called nedb in an Electron renderer process. It uses the browser field in its package.json to swap in a browser-based storage system. This is causing my database to not actually be persisted to…
acjay
  • 34,571
  • 6
  • 57
  • 100
4
votes
0 answers

Where does NeDB store its files in an Electron app?

I have an Electron app and I chose NeDB to store its data. I need to have access to the NeDB data files for reasons I am not willing to discuss. The problem I have is that even though I provide a file name and location, the data file does not get…
Tibi
  • 439
  • 7
  • 15
4
votes
1 answer

NedB on heroku dont keep db file

i used nedb in my nodejs app , first of my code is : var Datastore = require('nedb'); var db = new Datastore({ filename: 'users.db', autoload: true }); db.persistence.setAutocompactionInterval(5); everything is ok with local host , and database…
4
votes
2 answers

Nedb updates are adding new records instead of updating existing one

I'm really struggling with this so I'm hoping someone can help me to understand why I'm getting this behaviour. I have a file with the following records in it {"Id":"","documentPath":"mission.pdf","dName":"BIOLOGY TEST…
Lee
  • 61
  • 1
  • 4
4
votes
2 answers

Angular 2 (global variables): How do I access a variable defined in index.html, in the Typescript code?

I have this code: The Nedb persistent database is created. I just want to access the…
coder
  • 353
  • 5
  • 18
4
votes
1 answer

Does levelDB still corrupt data?

I am writing a small NodeJS app, where I need a DB of some sort. LevelDB (LevelUP) and NeDB seams to be the most popular, so which to choose... According to Wikipedia on 18th Nov. 2016, LevelDB often corrupt data. LevelDB is widely noted for being…
Jasmine Lognnes
  • 6,597
  • 9
  • 38
  • 58
4
votes
3 answers

NeDB not loading or storing to file

I cannot get the simplest example of NeDB to run properly. My code only works in-memory, persistence to file keeps failing without any error messages. The error callbacks for the loaddatabase and insert events always pass a null reference as error,…
Bo Mil
  • 41
  • 1
  • 3
4
votes
2 answers

Nedb Multiple Collection Single Datastore

I am a new to nedb. Its a kinda what sqlite is for sql community but for the node.js community. [https://github.com/louischatriot/nedb] I wanted to ask is possible to have multiple collections in a single database file (datastore). If there is,…
Adwin
  • 195
  • 2
  • 6
  • 21
3
votes
1 answer

parse NeDB file in golang

everyone! I'm new in programming, so, please, be lenient :) I have a .db file from NeDB that looks like…
rs256
  • 69
  • 6
3
votes
0 answers

How to get Electron app to connect to NeDB

I am building an Electron app using React.js. I am attempting to use NeDB as the recommended DB for Electron. However, I cannot get the app to connect to the database. When I move things around to troubleshoot or attempt to use an IPC I often get…
1
2 3
12 13