Hello

I`m having real trouble creating server side functions in orientDB. My idea 
is to write most of the complex functions in the orientDB server and the 
call these trough oriento (nodejs). 
However the most i can do in these server side functions is a single sql 
query, I am trying to for instance creating a JSON object and adding fields 
on it and returning it, but with no luck.

I have set up a graph database, consitsing of vertices (articles, users, 
providors, publications) and edges (read, starred, readLeater, contains, 
follows, published). The idea is to publish articles and magazines. 
<https://lh6.googleusercontent.com/-LN3D0OiFGos/VFtUCaoVQuI/AAAAAAAAAB0/mBHCj7AU_aU/s1600/Skjermbilde%2B2014-11-06%2Bkl.%2B11.55.54.png>Heres
 
a small example, i forinstance have a function to get all info for an 
article, in cluster #14 and i also wants to get its provider and if it is 
part of a publication (magazine) i want to get that too. I have made an 
functions that does this, but i cant seem to call it in the other 
serverside functions, not can i modify the JSON object created.

getArticle function:

var article = orient.getGraph().command("sql", "select from articles where 
>> @rid=?", [articleID]);
>
> return article
>
>
Have anyone any tips on serverside functions, or any sql tips&tricks.

Sorry if posting wrong or anything, but I am a bit lost in the orientDB sql 
world and the whole traverse/select etc.

Best regards
Kristoffer Larsen

-- 

--- 
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.

Reply via email to