I have
String toInsert = "somestring";
insert(toInsert);
and
insert(String toInsert) {
DBObject dbo = new BasicDBObject();
dbo.put("value" : toInsert);
}
In Mongo, this is saved as
{"value" : "somestring"}
But I would like it to be saved as
{"value" : somestring}
How can I change this to be saved it Mongo like this?
The 'somestring' I am trying to insert is a Javascript Function.