Live data from Hacker News

12 Months with MongoDB

blog.wordnik.com

71–75 of 75 posts

Re: 12 Months with MongoDB

#71
post #70
post #69

Earlier quoted context omitted.

Yes I've looked at them. I use them every day. The example you posted its difficult to parse because it deals with multidimensional arrays and also populating one in the inner query. The simple, and much more common case of one dimension arrays is very straightforward. Can you show me the equivalent in MongoDB? About the performance/scalability warning; I don't deal with very large arrays, a couple hundred items max,…

Sure, check out: http://www.mongodb.org/display/DOCS/Dot+Notation+%28Reaching...

I do not think that this is equivalent, it looks like querying complex JSON objects and not "simple" arrays.

From the "Array Element by Position" example:

  db.blogposts.find( { "comments.0.by" : "Abe" } )
PostgreSQL doesn't have JSON support but it does have XML/Xpath support.

If you stored XML documents in PostgreSQL the similar query to the MongoDB one would be something like this:

  select * from blogposts where (xpath('/comments[0]/@by', doc))::text[] = array['Abe']
Yes it's a little more verbose but not terrible so... at least in my opinion.

Re: 12 Months with MongoDB

#72
From the tutorial:

SELECT * FROM things WHERE name="mongo"

================================================

> db.things.find({name:"mongo"}).forEach(printjson); { "_id" : ObjectId("4c2209f9f3924d31102bd84a"), "name" : "mongo" }

I am having a hard time finding the benefit of that except you can do it programmatically and not step out of your language of choice and into SQL.

I am just looking into this...so maybe the lightbulb will get brighter as I go through the docs for MongoDB.

Re: 12 Months with MongoDB

#73
post #27

Earlier quoted context omitted.

While I don't support a blanket statements along the line of "every app should be using MongoDB," it is equally invalid to say that "anything that deals with money" has no use for MongoDB. If you look at http://www.mongodb.org/display/DOCS/Production+Deployments you will see a few financial and ecommerce sites. I can tell you that there are even more financial firms not on that list in various stages of production. E…

>you will see a few financial and ecommerce sites Could you provide some examples? Scanning the list I see a couple that have a very periphery relation to financials, but the actual applications have very little financial applicability (and the implementations are trivial). Though the person you responded to didn't actually say that `"anything that deals with money" has no use for MongoDB"', so you're setting up a st…

> so you're setting up a strawman

I find that ironic.

Re: 12 Months with MongoDB

#74
post #67

Earlier quoted context omitted.

I still think it is amazing the the free SQL databases don't have materialized views yet. MySQL's deficiencies aren't inherent to SQL databases. Other databases have faster query parsers and better query planners. It seems that with all the time and money invested into NoSQL solutions, Postgres could be improved to the level of Oracle or DB2.

This comment, which I completely agree with, really depresses me. People really like competing with each other rather than working together to build awesome solutions (and users often even /encourage/ this behavior with a pro-competition bias). The idea that we now have a million "sort of crummy" storage solutions rather than a couple, or even one, really good one--and mostly due to superficial differences in syntax…

I suddenly hope that by 2015 PostgreSQL ends up as the winner of the database wars, having embraced and outgrown every feature from every other data store out there.

Re: 12 Months with MongoDB

#75
post #27

Earlier quoted context omitted.

>you will see a few financial and ecommerce sites Could you provide some examples? Scanning the list I see a couple that have a very periphery relation to financials, but the actual applications have very little financial applicability (and the implementations are trivial). Though the person you responded to didn't actually say that `"anything that deals with money" has no use for MongoDB"', so you're setting up a st…

> so you're setting up a strawman I find that ironic.

That's nice.
Post reply on HN