Excellent Luca. How do I use math.js (which I installed) in Javascript functions? It obviously works in node. What does it take to reference it in a "Functions-function"?
On 12 July 2016 at 20:05, Luca Garulli <[email protected]> wrote: > You're right, just added this example: > > > https://github.com/orientechnologies/orientdb-docs/blob/master/Functions-Use.md#call-functions-via-sql > > It will go to the official documentation in the next hours. > > Best Regards, > > Luca Garulli > Founder & CEO > OrientDB LTD <http://orientdb.com/> > > > On 12 July 2016 at 12:50, Tore <[email protected]> wrote: > >> Indeed. I misread another thread. May be an explicit example should be >> included in the docs? >> Thanks again. >> >> On Tuesday, July 12, 2016 at 3:03:09 PM UTC+2, l.garulli wrote: >>> >>> Hi Tore, >>> >>> Sure you can call any function from SQL. >>> >>> Best Regards, >>> >>> Luca Garulli >>> Founder & CEO >>> OrientDB LTD <http://orientdb.com/> >>> >>> >>> On 12 July 2016 at 06:24, Tore <[email protected]> wrote: >>> >>>> Thanks Luca. >>>> Still, the question is really about using a function written in >>>> Studio/Functions. Lets assume I write a javascript >>>> function in Studio called snug(p), with one parameter. Can I use this >>>> in a select statement, e.g. select snug(Sfactor) from Foo... >>>> Saw some discussion about that somewhere. Can this be done? >>>> >>>> On Tuesday, July 12, 2016 at 4:03:09 AM UTC+2, l.garulli wrote: >>>>> >>>>> You can use the Java math for sure: >>>>> https://docs.oracle.com/javase/8/docs/api/java/lang/Math.html >>>>> >>>>> Example: >>>>> >>>>> var value = java.lang.Math.abs( v ); >>>>> >>>>> >>>>> >>>>> Best Regards, >>>>> >>>>> Luca Garulli >>>>> Founder & CEO >>>>> OrientDB LTD <http://orientdb.com/> >>>>> >>>>> >>>>> On 11 July 2016 at 14:09, Tore <[email protected]> wrote: >>>>> >>>>>> Trying to utilize math....() in a function (javascript). >>>>>> If this can be done, is there a way to use a function in a query? >>>>>> e.g. select math.asinh(XXX) as yyy from ... >>>>>> >>>>>> -- >>>>>> >>>>>> --- >>>>>> 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. >>>>>> >>>>> >>>>> -- >>>> >>>> --- >>>> 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. >>>> >>> >>> -- >> >> --- >> 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. >> > > -- > > --- > You received this message because you are subscribed to a topic in the > Google Groups "OrientDB" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/orient-database/38Oema7nruU/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- Tore Austrått phone +47 90657231 -- --- 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.
