python is going to die! =(

Carlos Ribeiro carribeiro at gmail.com
Wed Sep 22 21:32:36 EDT 2004


On Wed, 22 Sep 2004 17:40:43 -0300, Jorge Godoy <godoy at ieee.org> wrote:
> [about data aware components for Delphi]
> What are you using to replace those in your wxPython apps?  I really
> don't know them and I am not being able to help him with that.

TTable and TQuery equivalents are really not needed for Python "per
se". DBAPI 2.0 (even incomplete) and libraries such as sqlobject blow
TDataset and related classes away for almost anything that I can
imagine -- unless, of course, it's something that has to work wit data
aware editing components. These are still to be matched. I've been
studying Dabo (it was announced in this list, you can check it at
http://dabodev.com), and they are working on a framework that in some
ways resembles something that can be done with Delphi, but their
approach is different. Report generation is also problematic -- the
last time I've checked a couple of years ago, ReportLab couldn't be
considered to be on par with Delphi's report libraries, but I don't
about the situation now.

> I've seen, though, the wxODBC family but he always tells me that there
> are several penalties in performance for not using the native drivers in
> critical applications...  What is your opinion about it?

Passing over layers and layers of abstraction before getting to the
database is always going to impose a performance hit. ODBC is also
known to be very bad in this respect, at least in the Windows world,
and as far as I know, nobody likes to use it unless absolutely needed
for compatibility reasons.

I never made any benchmark, but I *suspect* that Python DB code can be
surprisingly efficient when compared to Delphi code. Delphi DB library
is very well implemented, but Python may have an edge when it comes to
manipulation of large in memory structures; not that Delphi can't do
it, but because Python libraries are already highly optimized. If one
writes "pythonic" code -- taking advantage of stuff that Python does
well, such as list and mapping manipulation, then the performance gain
can be significant. On the other hand, if someone tries to write code
in Python that reads and works just like Delphi's code, then the
performance will suffer.

-- 
Carlos Ribeiro
Consultoria em Projetos
blog: http://rascunhosrotos.blogspot.com
blog: http://pythonnotes.blogspot.com
mail: carribeiro at gmail.com
mail: carribeiro at yahoo.com



More information about the Python-list mailing list