Performance issues when upgrading from 0.38 to 0.39
"Cserna, Zsolt" <[email protected]> Wed, 26 Aug 2009 14:02:53 +0100
| Newsgroups | gmane.comp.python.sybase |
|---|---|
| Message-ID | <0FE1D5D2B5C6754898C9E32C1230EC6544BF719587@LNWEXMBX0105.msad.ms.com> |
This is a multi-part message in MIME format.
--_002_0FE1D5D2B5C6754898C9E32C1230EC6544BF719587LNWEXMBX0105m_
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
Hi all,
We've found performance drop in python-sybase when upgrading from 0.38 =
to 0.39.
We run it on Linux, python version 2.5.4 and python-sybase is linked to =
15.0.0.7 version of sybase client library.
The problem occur when we are fetching the results of a select query =
from the server. The difference between 0.38 and 0.39 is huge, we found =
0.39 is about 10-100 times slower than 0.38.
Please find the test script attached (rename it to .py). There's no =
difference in what table we select, it could contain text or number, it =
may have only one column or more columns.
Usually we get the following output when using 0.38:
Took 3.626094 seconds to fetch 10000 rows: 2757.788330 rows/second
And from 0.39:
Took 647.513509 seconds to fetch 10000 rows: 15.443693 rows/second
If I replace the line calling execute() to the following:
cursor.execute('SELECT top %d * FROM test_table' % rows, select=3DFalse)
...then in 0.39 it becomes fast, getting similar results as in 0.38.
It seems to me that using ct_cursor (which can be disabled by =
select=3DFalse) results the performance drop in 0.39.
Is there any reason to use ct_cursor or any drawback of not using it?
Is this problem general? Or does it occur in our enviroment?=20
Thank you in advance,
Zsolt
Zsolt Cserna
Morgan Stanley | IDEAS Practice Areas
Lechner Odon fasor 8 | Floor 07
Budapest, 1095
Phone: +36 1 881-3968
[email protected]
-------------------------------------------------------------------------=
-
NOTICE: If received in error, please destroy, and notify sender. Sender =
does not intend to waive confidentiality or privilege. Use of this email =
is prohibited when received in error. We may monitor and store emails to =
the extent permitted by applicable law.
--_002_0FE1D5D2B5C6754898C9E32C1230EC6544BF719587LNWEXMBX0105m_
Content-Type: text/plain;
name="syb_test_fetchall_simple.py.txt"
Content-Description: syb_test_fetchall_simple.py.txt
Content-Disposition: attachment; filename="syb_test_fetchall_simple.py.txt";
size=458
Content-Transfer-Encoding: base64
IyEvdXNyL2Jpbi9lbnYgcHl0aG9uCgppbXBvcnQgU3liYXNlCmltcG9ydCB0aW1lCgpkYiA9IFN5
YmFzZS5jb25uZWN0KERTTiwgVVNFUiwgUEFTU1dELCBkYXRhYmFzZT1EQk5BTUUsIGJ1bGtjb3B5
PTAsIGF1dG9fY29tbWl0PTApCgpyb3dzPTEwMDAwCmN1cnNvciA9IGRiLmN1cnNvcigpCmN1cnNv
ci5leGVjdXRlKCdTRUxFQ1QgdG9wICVkICogRlJPTSB0ZXN0X3RhYmxlJyAlIHJvd3MpCgpmZXRj
aF9zdGFydF90aW1lID0gdGltZS50aW1lKCkKcmVzID0gY3Vyc29yLmZldGNoYWxsKCkKZmV0Y2hf
ZW5kX3RpbWUgPSB0aW1lLnRpbWUoKQpmZXRjaF90aW1lID0gZmV0Y2hfZW5kX3RpbWUgLSBmZXRj
aF9zdGFydF90aW1lCnByaW50ICJUb29rICVmIHNlY29uZHMgdG8gZmV0Y2ggJWQgcm93czogJWYg
cm93cy9zZWNvbmQiICUgKGZldGNoX3RpbWUsIHJvd3MsIGZsb2F0KHJvd3MpL2ZldGNoX3RpbWUp
Cgo=
--_002_0FE1D5D2B5C6754898C9E32C1230EC6544BF719587LNWEXMBX0105m_
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now. http://p.sf.net/sfu/bobj-july
--_002_0FE1D5D2B5C6754898C9E32C1230EC6544BF719587LNWEXMBX0105m_
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
_______________________________________________
Python-sybase-misc mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/python-sybase-misc
--_002_0FE1D5D2B5C6754898C9E32C1230EC6544BF719587LNWEXMBX0105m_--