<div dir="ltr"><div class="MsoNormal" style="MARGIN: 0in 0in 0pt"><font size="3"><font face="Times New Roman"><span
style="FONT-SIZE:12pt; FONT-FAMILY: 'Times New Roman'; mso-fareast-font-family: 'Times New Roman'; mso-ansi-language:
EN-US;mso-fareast-language: EN-US; mso-bidi-language: AR-SA">Regarding: Optimizer To Do Item: Have EXPLAIN ANALYZE
issueNOTICE messages when the estimated and actual row counts differ by a specified
percentage.</span></font></font></div><divclass="MsoNormal" style="MARGIN: 0in 0in 0pt"><font size="3"><font
face="TimesNew Roman"></font></font> </div><div class="MsoNormal" style="MARGIN: 0in 0in 0pt"><font size="3"><font
face="TimesNew Roman"><p class="MsoNormal" style="MARGIN: 0in 0in 0pt"><font face="Times New Roman"
size="3">Hi,</font><divclass="MsoNormal" style="MARGIN: 0in 0in 0pt"><font size="3"><font face="Times New
Roman"> </font></font></div></font></font></div><pclass="MsoNormal" style="MARGIN: 0in 0in 0pt"><font face="Times New
Roman"size="3">After going through the thread related to the above mentioned to do Item, my understanding is
that:</font><pclass="MsoNormal" style="MARGIN: 0in 0in 0pt"><font size="3"><font face="Times New
Roman"> </font></font><pclass="MsoNormal" style="MARGIN: 0in 0in 0pt"><font face="Times New Roman" size="3">Issuing
noticeswhen a problematic node occurs is useful in the case of long running queries. It can avoid having the user wait
acouple of hours to solve the problem.</font><p class="MsoNormal" style="MARGIN: 0in 0in 0pt"><font size="3"><font
face="TimesNew Roman"> </font></font><p class="MsoNormal" style="MARGIN: 0in 0in 0pt"><font face="Times New Roman"
size="3">Apossible solution from the archives was summarized as below:</font><pre><span lang="EN"
style="mso-ansi-language:EN"><font face="Arial Unicode MS"> </font></span></pre> <pre><span lang="EN" style="FONT-SIZE:
12pt;FONT-FAMILY: Calibri; mso-ansi-language: EN; mso-bidi-font-size: 10.0pt">Bruce Momjian<span style="mso-spacerun:
yes"> </span>Wrote : </span></pre><pre><span lang="EN" style="FONT-SIZE: 12pt; FONT-FAMILY: Calibri;
mso-ansi-language:EN; mso-bidi-font-size: 10.0pt"> </span></pre> <pre><span lang="EN" style="FONT-SIZE: 12pt;
FONT-FAMILY:Calibri; mso-ansi-language: EN; mso-bidi-font-size: 10.0pt">I was thinking we could issue NOTICE when the
estimatesdiffered from</span></pre><pre><span lang="EN" style="FONT-SIZE: 12pt; FONT-FAMILY: Calibri;
mso-ansi-language:EN; mso-bidi-font-size: 10.0pt">the actual by a specified percentage, and that NOTICE could be
issued</span></pre><pre><span lang="EN" style="FONT-SIZE: 12pt; FONT-FAMILY: Calibri; mso-ansi-language: EN;
mso-bidi-font-size:10.0pt">while the query is still processing, assuming the stage completes
before</span></pre><pre><spanlang="EN" style="FONT-SIZE: 12pt; FONT-FAMILY: Calibri; mso-ansi-language: EN;
mso-bidi-font-size:10.0pt">the query does.<span style="mso-spacerun: yes"> </span>This seems much easier than doing
protocolchanges.</span></pre><p class="MsoNormal" style="MARGIN: 0in 0in 0pt"><font size="3"><font face="Times New
Roman"> </font></font><pclass="MsoNormal" style="MARGIN: 0in 0in 0pt"><font size="3"><font face="Times New
Roman"> </font></font><pclass="MsoNormal" style="MARGIN: 0in 0in 0pt"><font face="Times New Roman" size="3">Looking
forwardto your inputs on this. </font><p class="MsoNormal" style="MARGIN: 0in 0in 0pt"><font size="3"><font face="Times
NewRoman"> </font></font><p class="MsoNormal" style="MARGIN: 0in 0in 0pt"><font face="Times New Roman" size="3">Thank
you,</font>Ramya<br/><br /><div class="gmail_quote">On Thu, Jun 26, 2008 at 10:22 AM, Tom Lane <span dir="ltr"><<a
href="mailto:tgl@sss.pgh.pa.us">tgl@sss.pgh.pa.us</a>></span>wrote:<br /><blockquote class="gmail_quote"
style="PADDING-LEFT:1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid"><div class="Ih2E3d">"Ramya
Chandrasekar"<<a href="mailto:csekar.ramya@gmail.com">csekar.ramya@gmail.com</a>> writes:<br />> Regd: TODO
Item:Optimizer:: Have EXPLAIN ANALYZE issue NOTICE messages when<br /> > the estimated and actual row counts differ
bya specified percentage.<br /><br /></div>I think that TODO item hasn't been thought through very carefully.<br
/>NOTICEsthat are dissociated from the actual explain output seem pretty<br /> useless, or at least painful to use.
Youmight want to go back in the<br />archives and read the whole thread that led up to the TODO item to see<br />what
ideaswere kicked around.<br /><br /> regards, tom lane<br /></blockquote></div><br /></div>