DovetailDB
DovetailDBDitch Your Backend

DovetailDB is a schemaless, JSON-based database. Principal features:

DovetailDB needs more (vocal) users. If you use DovetailDB, please comment in the newsgroup about any issues you uncover and suggest how the product could be improved.

DovetailDB may be run as a standalone Java application, or as a servlet in the container of your choosing. It is licensed under the Apache License, 2.0.

Try It Out(right here and now)

Open up FireBug and go to the console tab, or any javascript console supported by your browser.

JQuery has already been imported onto this page; we will use it to access a DovetailDB instance. Frist, define a helper function to issue requests against a sandbox database like so:

>>>function calldb(action,args,cb){return $.ajax("http://dovetaildb.millstonecw.com:81/sandbox/"+action,{data:args,dataType:"jsonp"}).done(cb)}

Attempt to insert an object. You need to put it in a "bag", which is like a table in a traditional RDBMS. The object must contain a uniquely valued property named "id". Other than that, any JSON object will do:

>>>calldb("put",{bag:"people",entry:$.toJSON({id:"Phil",age:33})})

We should be able to retrieve this object by querying for it. To query for items, we use an object pattern; this pattern finds everyone older than 30:

>>>calldb("query",{bag:"people",query:$.toJSON({age:[">",30]})}, function(r){alert(r["result"][0].id)})

Now open the documentation in another window and take over the reins on your console.