COM Server data from python

Chris Farrow farrowch at gmail.com
Thu Apr 3 21:49:53 EDT 2014


On Wednesday, April 2, 2014 8:39:01 AM UTC-5, schapm... at gmail.com wrote:
> I am attempting to provide a bit of data through a com server I did a comparison of speed of my COM interface to ADODB and It seems massively slower.  I'm not sure if there is something I need to adjust or maybe that I am making so many calls to the COM server that each call takes time and possibly ADO is just buffering some data in chunks to my code.  This is mainly for an excel add-on that has not possibility to connect to mongodb except through an interface like this.
> 
> 
> 
>   I thought it was not really a big deal until I tested larger amounts of data and the speed took a nose dive.  For instance 10,000 records just to walk through and pull a couple fields.  ADO on the exact same data took only 1.5 seconds where my python code took close to 58 seconds to do the same thing.  I've played around with design etc.
> 
> 
> 
>   When i test the same code directly from python I get the same result if not better than I did with ADO.  Is there some bit of COM magic that I am missing.  Or is this because python is having to do more behind the scenes?
> 
> 
> 
> Thanks

Hi,

Did you implement your server using win32com? You might be better off looking for help on the python-win32 mailing list [1].

Regards,

Chris

[1] https://mail.python.org/pipermail/python-win32/



More information about the Python-list mailing list