Reputation: 805
Here's my problem:
The table will have key-value pairs and can have multiple values for same key.
Key Value
K1 V1
K1 V2
K2 V2
K2 V3
I will have only one type of queries:
What is the best way of doing this?
Upvotes: 1
Views: 66
Reputation: 7684
I would try mongodb
. You can store documents and query like that:
db.pairs.find(
{
value: { $in: [ v(i), v(i+1),...,v(j)] }
}
)
To find all elements:
db.pairs.find(
{
value: { $all: [ v(i), v(i+1),...,v(j)] }
}
)
Upvotes: 1