<p>Alexei Gradinari <strong>uploaded patch set #2</strong> to this change.</p><p><a href="https://gerrit.asterisk.org/10226">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">res_odbc: fix missing SQL error diagnostic<br><br>On SQL error there is not diagnostic information about this error.<br>There is only<br>WARNING res_odbc.c: SQL Execute error -1!<br><br>The function ast_odbc_print_errors calls a SQLGetDiagField to get the number<br>of available diagnostic records, but the SQLGetDiagField returns 0.<br>However SQLGetDiagRec could return one diagnostic records in this case.<br><br>Looking at many example of getting diagnostics error information<br>I found out that the best way it's to use only SQLGetDiagRec<br>while it returns SQL_SUCCESS.<br><br>Also this patch adds calls of ast_odbc_print_errors on SQL_ERROR<br>to res_config_odbc.<br><br>ASTERISK-28065 #close<br><br>Change-Id: Iba5ae5470ac49ecd911dd084effbe9efac68ccc1<br>---<br>M res/res_config_odbc.c<br>M res/res_odbc.c<br>2 files changed, 10 insertions(+), 7 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/26/10226/2</pre><p>To view, visit <a href="https://gerrit.asterisk.org/10226">change 10226</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/10226"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 13 </div>
<div style="display:none"> Gerrit-MessageType: newpatchset </div>
<div style="display:none"> Gerrit-Change-Id: Iba5ae5470ac49ecd911dd084effbe9efac68ccc1 </div>
<div style="display:none"> Gerrit-Change-Number: 10226 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: Alexei Gradinari <alex2grad@gmail.com> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins2 </div>