Has anybody here used MongoDB with Python?

30 views
Skip to first unread message

Mosab Ahmad

unread,
Oct 8, 2012, 10:21:50 PM10/8/12
to pyth...@googlegroups.com
Hello guys,

I have been reading for the last two days about mongodb, not the flame war, but I am seriously considering to use it in a new Portal project I am working on. Does anyone here have any experience, stories or advice to share?

Shehabic

unread,
Oct 9, 2012, 12:21:25 AM10/9/12
to pyth...@googlegroups.com
Hi Mosab,

I use MongoDB a lot but not with python, but I don't think it makes any difference, in the end all you pass to it is JSON or Multi-Dimensional Associative arrays (PHP) or Dictionaries (Python).

This is just a very brief example

to select with or condition:

{ '$or' : [ { 'x' : 1 } , { 'y' : 1 } ] }    <--------- This syntax is the same whatever your language is.

This means ( SELECT ............ WHERE  x='1' OR y='1' ) ..........etc          
 

mosab...@gmail.com

unread,
Oct 9, 2012, 12:34:52 AM10/9/12
to pyth...@googlegroups.com
Thank you so much Shehabic,

I get the syntax, and get the language neutrality part as well. What I am asking for is what are the limitations (other than the 32-bit systems, lack of transactions & full text search). What are the preferred aiding tools to use, when not to use it, what kind of hardware does it need, and how much memory doe it eat etc.

----------------------
Mosab Ahmad

Entrepreneur in the make

Cell : +201119942443
E-mail : mosab...@gmail.com
LinkedIn : http://www.linkedin.com/in/mosab
github : https://github.com/mos3abof




--
You received this message because you are subscribed to the Google Groups "python-eg" group.
To view this discussion on the web visit https://groups.google.com/d/msg/python-eg/-/Wr7EwPyePYsJ.

To post to this group, send email to pyth...@googlegroups.com.
To unsubscribe from this group, send email to python-eg+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/python-eg?hl=en.

Shehabic

unread,
Oct 9, 2012, 1:10:02 AM10/9/12
to pyth...@googlegroups.com
Well MongoDB isn't limited to 32-bit systems at all, it works on both 32 and 64 bit but it's much better on 64 bit,

Second performance wise it's much much faster that any SQL-Driven db cause of the fact that it keeps indexes in memory (which consumes some memory) but it's very fast, also its insert and read rate are far better than mysql and much-less resource consumer.

One of the greatest benefits of Mongo is that it's structureless DB i.e. each record can have its own structure of fields, i.e. if you decided to add fields to record in the future you don't have to cascade all these changes to the old records (but you can).

Finally if you're thinking about apps that scale widely then forget all the relational DBs and do it in your code, because JOINS for example creates a temporary tables which is a db killer for large amount of consequent users. e.g. Google Big Tables, Facebook's Cassandra, Even Facebook uses MySQL as a key-store DB without relations or Transactions.

Shehabic

unread,
Oct 9, 2012, 1:10:50 AM10/9/12
to pyth...@googlegroups.com
Well MongoDB isn't limited to 32-bit systems at all, it works on both 32 and 64 bit but it's much better on 64 bit,

Second performance wise it's much much faster that any SQL-Driven db cause of the fact that it keeps indexes in memory (which consumes some memory) but it's very fast, also its insert and read rate are far better than mysql and much-less resource consumer.

One of the greatest benefits of Mongo is that it's structureless DB i.e. each record can have its own structure of fields, i.e. if you decided to add fields to record in the future you don't have to cascade all these changes to the old records (but you can).

Finally if you're thinking about apps that scale widely then forget all the relational DBs and do it in your code, because JOINS for example creates a temporary tables which is a db killer for large amount of consequent users. e.g. Google Big Tables, Facebook's Cassandra, Even Facebook uses MySQL as a key-store DB without relations or Transactions.



Tamer Higazi

unread,
Dec 30, 2013, 7:52:27 AM12/30/13
to pyth...@googlegroups.com
Yes, me.....

I am currently doing a Zope Project along with ZODB with MongoDB.

What do you like to know I might share with you ?!


Tamer


On Tuesday, October 9, 2012 4:21:50 AM UTC+2, Mosab Ahmad wrote:
Reply all
Reply to author
Forward
0 new messages