views:

540

answers:

1

Wondering if it is possible to migrate from a document-based DB (eg. couchDB) to a RDBMS (eg. MySQL).

+2  A: 

Short Answer: Yes

The long Answer: the more features of an Document-DB (e.g. CouchDB) you use, the more pain you will feel. Concepts like complex map-reduce based "view" generation, complex, nested documents and the like don't map well to RDBMS.

Also thinks which are easy with CouchDB (Multi-Master with more than two Masters, Load balancing) are hard to nearly-impossible with RBMS.

On the other hand, applications which make heavy use of a real RDBMS (usually not mySQL) are much harder to port to CouchDB & friends, because they miss transactions and all the rest of the ACID properties. CouchDB provides much fewer guarantees in this regard. Therefore in general porting from couchdb is easier than porting to couchdb.

That said, many applications use RDBMS only as glorified (key, value) stores - these are easy to port in all directions.

mdorseif
hmmm, was under the impression going from couchdb -> rdbms would be straightforward. i'll have to look into that. thnx
mt3
We have several CouchDB applications which would take considerable effort to port to SQL. The couch views run a few hundred lines of javascript code in the "views" and uses CouchDB "triggers". All possible to emulate in SQL, but not easy.
mdorseif