did you ever fix this?
On Monday, 23 September 2013 08:09:16 UTC-4, Mattijs Meiboom wrote:
>
> I've been at his for a while, and completely boggled by the result of a
> function on my graph.
>
> (version: orientdb-graphed-1.3.0)
>
> I have the following function, setLocation(device_rid, location_rid) which
> sets a location for a device.
>
> - When I call it through the studio, it works as expected. I use rid
> parameters *without* # prefix and it returns a result containing the
> record for 1 edge. Executing select from InstalledIn then returns a
> list including that edge.
> - *However: *when I use the REST api (from python, not ideal but it
> should work), calling the function using
> POST
> http://<server_ip>:2480/function/<graph_name>/set_location/%2316%3a0/%2314%3a0,
>
> I get the same result containing an edge *but no edge is present in
> the cluster*!
>
> Some notes:
>
> - URL is encoded for /#16:0/#14:0
> - The function call does delete any pre-existing edges
> - The returned edge is always the same one, regardless of the RIDs.
> The version also increases in the returned edge.
>
> I am quite confused, am I missing some vital point? Is my edge not
> actually stored? Why is there a difference in behavior based on the way I
> call the function, and why does the REST api expect # prefixes and the web
> interface not?
>
> Any help is greatly appreciated!
>
> Thanks,
> Matthew
>
> function set_location(device_rid, location_rid)
> {
> // Remove old edges
> gdb.command("DELETE EDGE InstalledIn FROM " + device_rid);
> gdb.command("DELETE EDGE OwnedBy FROM " + device_rid);
>
> // Create new edge and return it
> return gdb.command("CREATE EDGE InstalledIn FROM " + device_rid + " TO "
> + location_rid);
> }
>
--
---
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.