234 questions
0
votes
1
answer
31
views
Firestore cardinality vs effective cardinality in Composite Indexing
My question is about indexing and cardinality in Firestore.
I have 3 fields:
owner_id: Thousands of users
domain: Hundreds of domains
category: Only 10 unique one
The composite index, which matches ...
2
votes
1
answer
4k
views
How many databases are allowed in a single mongodb cluster?
I'm working with a system that requires multiple databases for multiple organisation. A monolithic node Js server connects to these databases. The challenge is I may have 5000 organisation.
I wanted ...
0
votes
0
answers
22
views
Document stores (e.g. Firebase) - smaller documents or more updates?
I am learning Firebase after many years of using SQL RDBMSs. This is definitely a challenge.
Say, I have a collection of objects. Each object can belong to any number of categories. Categories have ...
0
votes
1
answer
327
views
How to delete nested collections from an empty document in Firestore?
I have the following structure for one of my collections on Firestore:
main_database/root/comments/{commentId}/message: str
main_database/root/comments/{commentId}/replies/{replyId}/message: str
I ...
0
votes
2
answers
137
views
Remove a child object in Fauna DB
I need to remove a child object in FQL. Let me demonstrate with the following example:
{
"1": {
"name": "test"
},
"2": {
"name&...
0
votes
1
answer
2k
views
How can I reduce the size of this JSON record?
I'm working on reducing the size of my database records. Each record is on average around 5Kb of which 97% is used by an single array property.
This array describe object on an image and their ...
1
vote
1
answer
392
views
How to un-nest and group collections in mongoDB
I'm don't understand how to unwind and then nested collections in mongoDB. basically I have two collections that are structured like this:
questions doc:
{
"_id" : 1,
"questions&...
0
votes
1
answer
441
views
How to query data from nested document in mongodb?
I'm struggling with this nested document too much. I tried to read the document and also follow other SO responses to see if it works for me, but I'm not getting the results that I'm looking for. I ...
0
votes
1
answer
248
views
How to save a single document field in cloud firestore into a local variable in flutter?
I would like to save a single document field into a local variable, but I am not able to do that.
Here is my code:
void getPostsData() async{
List<Widget> listItems = [];
String _title;
...
0
votes
3
answers
3k
views
How do I store a picture in azure blob storage in asp.net mvc application?
I am currently working on an ASP.Net application that stores student information. I am required to store the following information:
Student number
Name
Email address
Home address
Contact no.
Upload ...
3
votes
1
answer
218
views
Branch and Merge abilities in a Document Database?
When I think of a document database, I think of a bunch of JSON files. (I imagine it is more complex than that, but that is how envision it.)
In an upcoming project, we need the ability to deal with ...
2
votes
1
answer
134
views
How to partition my User Permission Data using CosmosDB
I have decided to use CosmosDB in order to store my users permissions data. Our permissions are very dynamic in nature and thus a non relational database makes sense.
For a permission database, it ...
1
vote
0
answers
58
views
Absorbing N in a M:N relationship
I am encountering an issue I am trying to wrap my head around. I am using learnmongodbthehardway as a resource to define my options modelling a M:N relationship. According to this link I have two ...
0
votes
0
answers
55
views
Document-databse implementaion of one-to-many relationship
Designing data intensive application by Martin Kleppmann says one-to-many relationship is implemented in document database using tree hierarchy. For example as given in code below user can hold ...
0
votes
1
answer
147
views
How to store locations in ArangoDB?
I am building a web application where I need to store a large number of unique addresses as nodes in ArangoDB.
One approach would be using a hierarchical graph model: a country node connected to ...
0
votes
1
answer
273
views
Query to get specific sub-doc using aggregation in mongoDB?
I'd like to know a query in which I could get a specific sub-doc using it's ObjectId- or even it's "store" name if it's easier- using the aggregation method. I'm pretty sure I can use $project but I'm ...
3
votes
2
answers
679
views
While creating new document in ravendb, collection name is missing in metadata, and the document is marked under @empty collection
I am trying to create a new collection in ravendb using the apollo node client. Although the document is created and stored in ravendb, the "collection" value from metadata is missing. And as a result ...
2
votes
1
answer
39
views
transforming foreign constraints in raven document db
I have following entity "MyEntity" in my RavenDb
{
Id: {Guid}
//...
//...
}
In the application there might occur a specific event relating to elements of MyEntity.
Not I want to associate users ...
2
votes
1
answer
63
views
Couchbase modeling techniques
I'm doing some research for my team, trying to understand couchbase. Right now, I'm looking at modeling practices in couchbase.
I found this article, written in August 2016, that talks about ...
0
votes
1
answer
2k
views
Store "extended" metadata on entities stored in Azure Cosmos DB as JSON documents
We are building a REST API in .NET deployed to Azure App Service / Azure API App. From this API, client can create "Products" and query "Products". The product entity has a set of ...
0
votes
0
answers
73
views
Generalized DocumentDB / CosmosDB Partitioning Strategy
From all the research I've done it seems that even when using a partition key in CosmosDB/DocumentDB you may run into an issue with capacity if that partition hits the 10gb limit. I've seen strategies ...
0
votes
1
answer
2k
views
Querying nested subtrees in Cosmos DB
Let's say I have a parent-child-grandchild-etc relationship in a Cosmos document, represented by the following JSON:
"id": "someUniqueString",
"peepsNkids": [
"Jane": [
"Joe": [],
...
0
votes
1
answer
2k
views
Multiple partitions in COSMOS DB collection
1) I have a Cosmos DB collection with about 500k documents and which is Partitioned by a property "SITEID". In the Query Request Options only one partition key value can be passed. In my case I have ...
2
votes
1
answer
6k
views
Firestore multiple querys on the same field [duplicate]
We are building a app where we need to show nearby posts, made by users. A post should only be shown, if it is not more as 4 hours since posting. Because firestore doesn't provide geoquerys, i have to ...
2
votes
1
answer
923
views
Property reference is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause
Azure Cosmos Document DB throws an error on executing a query like this -
SELECT DISTINCT VALUE
{
DocumentName: c.Name,
Count: COUNT(c.id),
Target: c.Target
}
FROM c where c.Target != ...