We have a data structure that looks something like this (the class name is
"model", and there is presently only one document in the class):
{
"data": [
{"value": 0},
{"value": 1},
{"value": 2}
]
}
I would like to update the value of one of the elements in the array. I
was trying to use the following SQL Query:
UPDATE model SET data[0] = "some other value"
The expected result was a document that looks like this:
{
"data": [
"some other value",
{"value": 1},
{"value": 2}
]
}
However, the query succeeds, but the update does not happen.
Not that doing this query:
UPDATE model SET data[0].value = "some other value"
Correctly updates the document to look like this:
{
"data": [
{"value": "some other value"},
{"value": 1},
{"value": 2}
]
}
I also tried to simplify this:
{
"data": ["a", "b", "c"]
}
UPDATE model SET data[0] = "x"
I was hoping to replace the "a" with the "x", but nothing happens.
I am using 2.0.13.
Any ideas?
--
---
You received this message because you are subscribed to the Google Groups
"OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.