Cannot execute embedded R in MonetDB
Hi, We are having issues when executing embedded R in a MonetDB SQL function. We have compiled and configured MonetDB accordingly, so as to be able to run embedded R; however, the simple example in the documentation fails to execute. This is the function we have: create function rapi00() returns table( d int ) language R { return seq(1,10); }; Having just "seq(1,10)" doesn't make any difference either. When this function gets created, we don't get any error; however, when we do the following: select d from rapi00() as r where d > 5; we get the this error: Query failed: TypeException:user.s6_3[3]:'rapi.eval' undefined in: X_4:bat[:int] := rapi.eval(7fdb9830e210:ptr,"{\n\treturn seq(1,10);\n};":str); We don't know how to tackle this issue. We have followed the process from https://www.monetdb.org/content/embedded-r-monetdb. Do you have any suggestion to make this work? Thanks! Luis Ángel. The information transmitted, including any attachments, is intended only for the individual or entity to which it is addressed, and may contain confidential and/or privileged information. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by individuals or entities other than the intended recipient is prohibited, and all liability arising therefrom is disclaimed. If you have received this communication in error, please delete the information from any computer and notify the sender.
Hello Luis, It works for me. I just grabbed my installation of “default” several days ago, and copy-pasted the example from [1], and it works as expected. I started my server as this: $ mserver5 --dbpath=/tmp/test --set embedded_r=true Then in a mclient session: $ mclient Welcome to mclient, the MonetDB/SQL interactive terminal (unreleased) Database: MonetDB v11.28.0 (unreleased), 'test' Type \q to quit, \? for a list of available commands auto commit mode: on sql>CREATE FUNCTION rapi00() RETURNS TABLE (d INTEGER) LANGUAGE R { seq(1,10); }; operation successful (3.419ms) sql>SELECT d FROM rapi00() AS r WHERE d > 5; +------+ | d | +======+ | 6 | | 7 | | 8 | | 9 | | 10 | +------+ 5 tuples (1.967ms) If your problem persist, can you please let us know: - which monetdb version are you using? - how did you start your mserver5? - which monetdb client do you use? Kind regards, Jennie [1] https://www.monetdb.org/content/embedded-r-monetdb
On 23 May 2017, at 20:23, Luis Larios
wrote: Hi,
We are having issues when executing embedded R in a MonetDB SQL function. We have compiled and configured MonetDB accordingly, so as to be able to run embedded R; however, the simple example in the documentation fails to execute.
This is the function we have:
create function rapi00() returns table( d int ) language R { return seq(1,10); };
Having just “seq(1,10)” doesn’t make any difference either. When this function gets created, we don’t get any error; however, when we do the following:
select d from rapi00() as r where d > 5;
we get the this error:
Query failed: TypeException:user.s6_3[3]:'rapi.eval' undefined in: X_4:bat[:int] := rapi.eval(7fdb9830e210:ptr,"{\n\treturn seq(1,10);\n};":str);
We don’t know how to tackle this issue. We have followed the process from https://www.monetdb.org/content/embedded-r-monetdb. Do you have any suggestion to make this work?
Thanks!
Luis Ángel. The information transmitted, including any attachments, is intended only for the individual or entity to which it is addressed, and may contain confidential and/or privileged information. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by individuals or entities other than the intended recipient is prohibited, and all liability arising therefrom is disclaimed. If you have received this communication in error, please delete the information from any computer and notify the sender.
_______________________________________________ users-list mailing list users-list@monetdb.org https://www.monetdb.org/mailman/listinfo/users-list
participants (2)
-
Luis Larios
-
Ying Zhang