<div dir="ltr"><div>Oops, the previous email was sent when I pasted the source code.</div><div><br></div><div>Continue ....</div><div><br></div>I can't find any detailed information about the issue OTP-5759.<div><br></div><div>IMHO, the else branch is good enough for this code block. In particular, we can replace that code block by:</div><div><br></div><div><table class="gmail-highlight gmail-tab-size gmail-js-file-line-container" style="box-sizing:border-box;border-collapse:collapse;color:rgb(51,51,51);font-family:-apple-system,blinkmacsystemfont,"segoe ui",helvetica,arial,sans-serif,"apple color emoji","segoe ui emoji","segoe ui symbol";font-size:14px"><tbody style="box-sizing:border-box"><tr style="box-sizing:border-box"><td id="gmail-LC665" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre"><span class="gmail-pl-c" style="box-sizing:border-box;color:rgb(150,152,150)">/* Handle multiple result sets */</span></td></tr><tr style="box-sizing:border-box"><td id="gmail-L666" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC666" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">   <span class="gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">do</span> {</td></tr><tr style="box-sizing:border-box"><td id="gmail-L667" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC667" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">           <span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">ei_x_encode_list_header</span>(&<span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">dynamic_buffer</span>(state), <span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">1</span>);</td></tr><tr style="box-sizing:border-box"><td id="gmail-L668" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC668" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">           msg = <span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">encode_result</span>(state);</td></tr><tr style="box-sizing:border-box"><td id="gmail-L669" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC669" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">       <span class="gmail-pl-c" style="box-sizing:border-box;color:rgb(150,152,150)">/* We don't want to continue if an error occured */</span></td></tr><tr style="box-sizing:border-box"><td id="gmail-L670" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC670" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">          <span class="gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">if</span> (msg.<span class="gmail-pl-smi" style="box-sizing:border-box">length</span> != <span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">0</span>) { </td></tr><tr style="box-sizing:border-box"><td id="gmail-L671" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC671" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">            <span class="gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">break</span>;</td></tr><tr style="box-sizing:border-box"><td id="gmail-L672" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC672" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">         }</td></tr><tr style="box-sizing:border-box"><td id="gmail-L673" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC673" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">     msg = <span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">more_result_sets</span>(state);</td></tr><tr style="box-sizing:border-box"><td id="gmail-L674" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC674" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">            <span class="gmail-pl-c" style="box-sizing:border-box;color:rgb(150,152,150)">/* We don't want to continue if an error occured */</span></td></tr><tr style="box-sizing:border-box"><td id="gmail-L675" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC675" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">          <span class="gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">if</span> (msg.<span class="gmail-pl-smi" style="box-sizing:border-box">length</span> != <span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">0</span>) { </td></tr><tr style="box-sizing:border-box"><td id="gmail-L676" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC676" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">            <span class="gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">break</span>;</td></tr><tr style="box-sizing:border-box"><td id="gmail-L677" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC677" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">         }</td></tr><tr style="box-sizing:border-box"><td id="gmail-L678" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC678" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre"> } <span class="gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">while</span> (<span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">exists_more_result_sets</span>(state)); </td></tr><tr style="box-sizing:border-box"><td id="gmail-L679" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC679" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">     </td></tr><tr style="box-sizing:border-box"><td id="gmail-L680" class="gmail-blob-num gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="gmail-LC680" class="gmail-blob-code gmail-blob-code-inner gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre">      <span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">ei_x_encode_empty_list</span>(&<span class="gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">dynamic_buffer</span>(state));</td></tr></tbody></table></div><div><br></div><div><br></div><div>I am afraid that doing so will re-surface the issue reported by OTP-5759. </div><div>If you have detailed information(for example: bug report, how it was fixed), please share with me.</div><div><br></div><div>Thanks,</div><div>Tuan</div><div><br></div><div><br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 16, 2016 at 10:33 AM, Tuan Cao <span dir="ltr"><<a href="mailto:tuanbeo0502@gmail.com" target="_blank">tuanbeo0502@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Erlang community,<div><br></div><div><br></div><div>When running multi-statement request in which the first statement returns zero rows, the Erlang ODBC App returns wrong result.</div><div><br></div><div>To reproduce:</div><div>







<p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">1> odbc:start().</span></p>
<p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">ok</span></p>
<p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">2> {ok, Ref}=odbc:connect("Driver=ODBC Driver 13 for SQL Server;Server=XXX;Database=<wbr>YYY;Uid=ZZZ;Pwd=PPP;Encrypt=<wbr>yes;TrustServerCertificate=no;<wbr>Connection Timeout=30;", []).</span></p>
<p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">{ok,<0.40.0>}</span></p>
<p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">3> odbc:sql_query(Ref, "create table z1(i integer);").</span></p>
<p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">{updated,undefined}</span></p>
<p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">4> odbc:sql_query(Ref, "insert into z1 select * from z1 where 1<0; select 1;").</span></p>
<p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">{updated,0}</span></p><p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1"><br></span></p><p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">As you can see, odbc_sql_query only returns the first result, and ignore all subsequence results.</span></p><p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1">Looking at the source code, I found that this code block swallow subsequence result:</span></p><p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1"><br></span></p><p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1"></span></p><table class="m_2354456810770641854gmail-highlight m_2354456810770641854gmail-tab-size m_2354456810770641854gmail-js-file-line-container" style="box-sizing:border-box;border-collapse:collapse;color:rgb(51,51,51);font-family:-apple-system,blinkmacsystemfont,"segoe ui",helvetica,arial,sans-serif,"apple color emoji","segoe ui emoji","segoe ui symbol";font-size:14px"><tbody style="box-sizing:border-box"><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-LC661" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap"><br class="m_2354456810770641854gmail-Apple-interchange-newline">    <span class="m_2354456810770641854gmail-pl-c" style="box-sizing:border-box;color:rgb(150,152,150)">/* OTP-5759, fails when 0 rows deleted */</span></td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L662" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC662" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">  <span class="m_2354456810770641854gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">if</span> (result == SQL_NO_DATA_FOUND) {</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L663" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC663" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">     msg = <span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">encode_result</span>(state);</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L664" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC664" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">    } <span class="m_2354456810770641854gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">else</span> {</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L665" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC665" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">    <span class="m_2354456810770641854gmail-pl-c" style="box-sizing:border-box;color:rgb(150,152,150)">/* Handle multiple result sets */</span></td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L666" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC666" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">   <span class="m_2354456810770641854gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">do</span> {</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L667" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC667" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">      <span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">ei_x_encode_list_header</span>(&<span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">dynam<wbr>ic_buffer</span>(state), <span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">1</span>);</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L668" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC668" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">         msg = <span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">encode_result</span>(state);</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L669" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC669" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">          <span class="m_2354456810770641854gmail-pl-c" style="box-sizing:border-box;color:rgb(150,152,150)">/* We don't want to continue if an error occured */</span></td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L670" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC670" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">     <span class="m_2354456810770641854gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">if</span> (msg.<span class="m_2354456810770641854gmail-pl-smi" style="box-sizing:border-box">length</span> != <span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">0</span>) { </td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L671" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC671" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">             <span class="m_2354456810770641854gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">break</span>;</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L672" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC672" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">            }</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L673" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC673" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">     msg = <span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">more_result_sets</span>(state);</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L674" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC674" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">       <span class="m_2354456810770641854gmail-pl-c" style="box-sizing:border-box;color:rgb(150,152,150)">/* We don't want to continue if an error occured */</span></td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L675" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC675" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">     <span class="m_2354456810770641854gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">if</span> (msg.<span class="m_2354456810770641854gmail-pl-smi" style="box-sizing:border-box">length</span> != <span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">0</span>) { </td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L676" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC676" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">             <span class="m_2354456810770641854gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">break</span>;</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L677" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC677" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">            }</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L678" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC678" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap"> } <span class="m_2354456810770641854gmail-pl-k" style="box-sizing:border-box;color:rgb(167,29,93)">while</span> (<span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">exists_more_result_sets</span>(<wbr>state)); </td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L679" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC679" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">        </td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L680" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC680" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">      <span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">ei_x_encode_empty_list</span>(&<span class="m_2354456810770641854gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,134,179)">dynami<wbr>c_buffer</span>(state));</td></tr><tr style="box-sizing:border-box"><td id="m_2354456810770641854gmail-L681" class="m_2354456810770641854gmail-blob-num m_2354456810770641854gmail-js-line-number" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;color:rgba(0,0,0,0.298039);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_2354456810770641854gmail-LC681" class="m_2354456810770641854gmail-blob-code m_2354456810770641854gmail-blob-code-inner m_2354456810770641854gmail-js-file-line" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;word-wrap:normal;white-space:pre-wrap">    }</td></tr></tbody></table><p class="m_2354456810770641854gmail-p1"><span class="m_2354456810770641854gmail-s1"><br></span></p></div></div>
</blockquote></div><br></div>