Questions tagged [rxdb]
44 questions
7
votes
1 answer
RxDB - Use the existing local DB
Case
How to open an existing database?
Issue
I already create one database with RxDB.create(), and created some collections, put some documents in it
So, in another script, i want to open that database to execute some queries, but I don't know how…

Andon Mitev
- 1,354
- 1
- 11
- 30
4
votes
1 answer
How Do I Properly Initialize RxDB in a Vue App with global
I'm trying out RxDB for the first time in a Vue 3 app, and getting started is a bit more tricky than I expected (and it's probably my fault).
I installed RxDB with NPM in my project ("rxdb": "^9.20.0"), then I did this in my main.js file:
import {…

Clifton Labrum
- 13,053
- 9
- 65
- 128
4
votes
1 answer
How to handle JWT authentication with RxDB?
I have a local RxDB database and I want to connect it with CouchDB. Everything seems to works fine except for authentication. I have no idea how to add it differently then inserting credentials in database url:
database.tasks.sync({
remote:…

Alan Wołejko
- 442
- 2
- 5
- 20
3
votes
0 answers
Rxdb sync not update db
There are 3 bases (front, node, remote). Front <=> node, node <=> remote. When the front base is updated, the data goes to the remote base, but the node is not updated. In theory, the node should be updated first, and then the remote base.
Render…

Denis Makarov
- 31
- 1
3
votes
0 answers
possible to generate RxDB schema from existing graphql schema?
Curious if this is possible, I see graphQLSchemaFromRxSchema for working in the other direction, but we already have a graphQL schema we want to use.

Chris Drackett
- 1,248
- 2
- 10
- 22
3
votes
1 answer
RxDb, cannot sort on field(s) XXX when using the default index
I just discovered RxDb, which as far as I understand is running PouchDB underneath, in any case, I have defined a fairly simple schema for an entity:
let nodeSchema: RxJsonSchema = {
version: 0,
title: `node schema`,
description:…

Oscar Franco
- 5,691
- 5
- 34
- 56
3
votes
1 answer
RxDB - Document update conflict (error 409)
I use RxDB and want to update the document in it.
This is how the db is created:
const _create = async function() {
const db = await RxDB.create({
name: 'myName',
adapter: process.env.NODE_ENV === 'test' ? 'memory' : 'idb',
password:…

max
- 612
- 7
- 26
2
votes
0 answers
Rxdb infinitely pulling in replicateRxCollection
I'm working with rxdb and I have pull and push handlers for the backend I have used supabase
I have setup the code for replication as follows:
replication.ts
import { RxDatabase } from "rxdb";
import { RxReplicationPullStreamItem } from…

Rohan Keskar18
- 193
- 1
- 10
2
votes
1 answer
How to update local data from rxdb to server database postgrasql through graphql in react
we are trying rxdb as local database and postgresql as a server database and through graphql end point we are able to push and pull data from local to server and vice-versa but how to update and delete data so that it can replicate in both databases…

Sheethal Patil
- 21
- 1
2
votes
0 answers
RxDB check if a local database exists
How can I find out whether the local db (indexedDB) with a given name already exists?
const db = await createRxDatabase({
name: 'heroesdb',
storage: getRxStoragePouch('idb'),
});
This approach, which is provided by the docs, just silently…

Ilya Loskutov
- 1,967
- 2
- 20
- 34
2
votes
0 answers
Uncaught (in promise) ReferenceError: process is not defined when calling createRxDatabase in aurelia app
I am trying to use rxdb as a store for my aurelia app. I have not found a plugin that implements this aleady, so start writing my own solution. I am using aurelia-cli 2.0.3, aurelia-loader-nodejs 1.1.0 and aurelia-webpack-plugin 5.0.3 with rxdb…

harfel
- 302
- 3
- 14
2
votes
1 answer
Is there a way to auto increment a number field in RxDB?
I've got a simple schema:
export default {
title: 'hash schema',
version: 0,
primaryKey: 'hash',
type: 'object',
keyCompression: true,
properties: {
uuid: { type: 'string' },
id: { type: 'number' }
}
}
I want to have a table…

Kasper Seweryn
- 356
- 1
- 7
- 14
2
votes
0 answers
package.json entry points with rollup and @rollup/plugin-node-resolve
I'm looking for some help with package.json entry points (i.e. with @rollup/plugin-node-resolve, with snowpack). For a package I'm importing (indirectly via RxDB), I'm having some issues and according to its maintainer, it's just not choosing the…

user1224598
- 101
- 3
2
votes
0 answers
Rxdb: Purge deleted items and old revisions by manually replicating (copying) rxdb database?
I'm looking for a way to replicate an rxdb instance locally, in the browser (local storage to local storage). I read somewhere that this is the only way to purge deleted items (can't find the link now). Actually, what I would like to do is:
purge…

yen
- 1,769
- 2
- 15
- 43
1
vote
0 answers
Electron - unable to use rxdb in vuejs renderer process
I'm trying to use rxDB inside my electron vue app. I've followed the guide on how to implement it inside the renderer process, and I have the following code in my App.vue file:
// Importo dipendenze front-end
import { store } from…

ICTDEV
- 227
- 1
- 10