Hi, I'm new to couchdb, and I apologize if this is a FAQ, but I can't seem to find what I'm looking for anywhere. I'm trying to understand the intended usage pattern for applications using couchdb as a data store. Specifically, I'm wondering what the intended approach to differentiating between different types of documents are.
For example, if my application has two entities: Cars and Trucks, in a RDBMS I'd create two different tables; one to store Cards and one to store Trucks. If I wanted cars I'd run a query on the "cars" table; if I wanted trucks I'd run a query on the "trucks" table. I'm a little unclear on how to achieve a similar use case with couchdb. I guess I could create separate databases for Cars and Trucks, but that doesn't seem right; I'm dubious that the designers intended databases to be used like tables. In searching the mailing list I saw that some documents had a field named "type". That seems like a good way to differentiate document types; my hesitation there is that it just seems very ad-hoc; I'd be surprised if there's no more firmly established method for distinguishing between document types. Apologize if this doesn't make much sense, I'm up later than I should be. Thanks! -- Avi Flax » Lead Technologist » Partner » Arc90 » http://arc90.com
