<div dir="ltr"><div>Andrey:<br><br></div>  Good catch. I have added the following to the quickref documentation for the "connection" class:<br><br><blockquote style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex" class="gmail_quote">.timeout # supply a value for CommandTimeout. Note: the "timeout" connection value is stored in this attribute, and is used as the connection timeout. It is then re-used as the command timeout. The user may overcome this rather goofy "feature" by supplying a different value to this attribute after the connection is made. The value is in seconds, and will be used for all subsequent SQL commands.<br></blockquote><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Aug 20, 2015 at 1:20 PM, Andrey Glozman <span dir="ltr"><<a href="mailto:aglozman@ellington.com" target="_blank">aglozman@ellington.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div link="blue" vlink="purple" lang="EN-US">
<div>
<p class="MsoNormal"><span style="color:#1f497d">Please disregard. <u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">We found a way to change timeout on the “connection†object.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d"><u></u>Â <u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">Thank you,<u></u><u></u></span></p><span class="">
<div>
<p class="MsoNormal"><span style="color:#1f497d">Â Â Andrey Glozman<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">Â Â Ellington Management Group, LLC<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">Â Â 53 Forest Avenue, Old Greenwich, CT 06870<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">Â Â <b>P</b>: <a href="tel:203.409.3574" value="+12034093574" target="_blank">203.409.3574</a>, <b>M</b>:<a href="tel:203.912.7099" value="+12039127099" target="_blank">203.912.7099</a>Â
<b>F</b>: <a href="tel:203.698.0869" value="+12036980869" target="_blank">203.698.0869</a><u></u><u></u></span></p>
</div>
<p class="MsoNormal"><span style="color:#1f497d"><u></u>Â <u></u></span></p>
</span><div>
<div style="border:none;border-top:solid #b5c4df 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Andrey Glozman
<br>
<b>Sent:</b> Thursday, August 20, 2015 12:46 PM<br>
<b>To:</b> '<a href="mailto:python-win32@python.org" target="_blank">python-win32@python.org</a>'<br>
<b>Subject:</b> adodbapi 2.6.0.7 question<u></u><u></u></span></p>
</div>
</div><div><div class="h5">
<p class="MsoNormal"><u></u>Â <u></u></p>
<p class="MsoNormal">Greetings, <u></u><u></u></p>
<p class="MsoNormal">We are trying to use the adodbapi 2.6.0.7 and unable to change ADO CommandTimeout after connection is established. Would you be able to help us understand the best way to do it?
<u></u><u></u></p>
<p class="MsoNormal"><u></u>Â <u></u></p>
<p class="MsoNormal">Based on the adodbapi code – the only “timeout†parameter a user can provide is at the connection object instantiation. That timeout value is being used as a ConnectionTimeout (to connect to a server) and a CommandTimeout (to execute statement).<u></u><u></u></p>
<p class="MsoNormal">Also, it is not clear how one can change CommandTimeout in between queries.
<u></u><u></u></p>
<p class="MsoNormal"><u></u>Â <u></u></p>
<p class="MsoNormal">Example case scenario: <u></u><u></u></p>
<p><u></u><span>1)<span style="font:7.0pt "Times New Roman"">Â Â Â Â Â
</span></span><u></u>Connect to a server (here we need ConnectionTimeout). Typically default 30 seconds is acceptable<u></u><u></u></p>
<p><u></u><span>2)<span style="font:7.0pt "Times New Roman"">Â Â Â Â Â
</span></span><u></u>Run Query1 Â - it might be some sort of a ping / database availability / user permissions / etc. (Here we need CommandTimeout). In many cases default 30 seconds is too much.
<u></u><u></u></p>
<p><u></u><span>3)<span style="font:7.0pt "Times New Roman"">Â Â Â Â Â
</span></span><u></u>Run Query2 – it might be a job / report / process - (here we need different CommandTimeout than above). In some cases it takes minutes to run.<u></u><u></u></p>
<p class="MsoNormal"><u></u>Â <u></u></p>
<p class="MsoNormal">Again, it seems that with existing implementation the above use case scenario is not possible.
<u></u><u></u></p>
<p class="MsoNormal"><u></u>Â <u></u></p>
<p class="MsoNormal">Thank you in advance,<u></u><u></u></p>
<p class="MsoNormal">Â Â Andrey Glozman<u></u><u></u></p>
<p class="MsoNormal">Â Â Ellington Management Group, LLC<u></u><u></u></p>
<p class="MsoNormal">Â Â 53 Forest Avenue, Old Greenwich, CT 06870<u></u><u></u></p>
<p class="MsoNormal">Â Â <b>P</b>: <a href="tel:203.409.3574" value="+12034093574" target="_blank">203.409.3574</a>, <b>M</b>:<a href="tel:203.912.7099" value="+12039127099" target="_blank">203.912.7099</a>Â <b>F</b>: <a href="tel:203.698.0869" value="+12036980869" target="_blank">203.698.0869</a><u></u><u></u></p>
<p class="MsoNormal"><u></u>Â <u></u></p>
</div></div></div><div><div class="h5">
<br>=============================================================================================<br>
Email transmissions can not be guaranteed to be secure or error-free, as information
could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain
viruses. The sender therefore does not accept liability for any errors or omissions in
the contents of this message which arise as a result of email transmission. In addition,
the information contained in this email message is intended only for use of the
individual or entity named above. If the reader of this message is not the intended
recipient, or the employee or agent responsible to deliver it to the intended recipient,
you are hereby notified that any dissemination, distribution,or copying of this communication,
disclosure of the parties to it, or any action taken or omitted to be taken in reliance on it,
is strictly prohibited, and may be unlawful. If you are not the intended recipient please
delete this email message.
==============================================================================================
  Â  </div></div></div>
<br>_______________________________________________<br>
python-win32 mailing list<br>
<a href="mailto:python-win32@python.org">python-win32@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/python-win32" rel="noreferrer" target="_blank">https://mail.python.org/mailman/listinfo/python-win32</a><br>
<br></blockquote></div><br></div>