mongoid/mongoid — Issue #1538: Is there a way to call Mongo Server-side function with db.eval()?
Author: raygao
Created: 2011-12-31 03:56:31+00:00
State: open

Hi,
Is there a way in Mongoid to call server-side function, like below

>db.system.js.save({ "_id" : "echo", "value" : function(x){return x;} })
>db.eval("echo('test')")

I cannot find any method on that?

Thanks,

-Ray