<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[FrontAccounting forum — FA2.4.4 Aged Supplier Analysis]]></title>
		<link>https://frontaccounting.com/punbb/viewtopic.php?id=7566</link>
		<atom:link href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=7566&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in FA2.4.4 Aged Supplier Analysis.]]></description>
		<lastBuildDate>Sat, 16 Jun 2018 06:50:40 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: FA2.4.4 Aged Supplier Analysis]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=31913#p31913</link>
			<description><![CDATA[<p>Thank you all. It is working now.</p>]]></description>
			<author><![CDATA[null@example.com (seahawk)]]></author>
			<pubDate>Sat, 16 Jun 2018 06:50:40 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=31913#p31913</guid>
		</item>
		<item>
			<title><![CDATA[Re: FA2.4.4 Aged Supplier Analysis]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=31910#p31910</link>
			<description><![CDATA[<p>@poncho1234</p><p>Thanks for finding this nasty bug. And for your solution. <a href="https://sourceforge.net/p/frontaccounting/git/ci/master/tree/purchasing/includes/db/suppliers_db.inc">Committed to Repo</a>.</p><p>/Joe</p>]]></description>
			<author><![CDATA[null@example.com (joe)]]></author>
			<pubDate>Sat, 16 Jun 2018 05:52:49 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=31910#p31910</guid>
		</item>
		<item>
			<title><![CDATA[Re: FA2.4.4 Aged Supplier Analysis]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=31908#p31908</link>
			<description><![CDATA[<p>The sql output gives 40 opening brackets, but 44 closing brackets???<br /></p><div class="codebox"><pre><code>SELECT supp.supp_name, supp.curr_code, 0_payment_terms.terms,

        Sum(IFNULL(IF (trans.type=20 OR trans.type=2
      OR (trans.type=0 AND (trans.ov_amount + trans.ov_gst + trans.ov_discount)&gt;0), 1, -1)*
            ABS(trans.ov_amount + trans.ov_gst + trans.ov_discount) - trans.alloc),0)) AS Balance,

        Sum(IF ((TO_DAYS(&#039;2018-06-15&#039;) - TO_DAYS(IF (trans.type=20 OR trans.type=21,trans.due_date,trans.tran_date))) &gt; 0,IF (trans.type=20 OR trans.type=2
      OR (trans.type=0 AND (trans.ov_amount + trans.ov_gst + trans.ov_discount)&gt;0), 1, -1)*
            ABS(trans.ov_amount + trans.ov_gst + trans.ov_discount) - trans.alloc),0)) AS Due,
        Sum(IF ((TO_DAYS(&#039;2018-06-15&#039;) - TO_DAYS(IF (trans.type=20 OR trans.type=21,trans.due_date,trans.tran_date))) &gt; 30,IF (trans.type=20 OR trans.type=2
      OR (trans.type=0 AND (trans.ov_amount + trans.ov_gst + trans.ov_discount)&gt;0), 1, -1)*
            ABS(trans.ov_amount + trans.ov_gst + trans.ov_discount) - trans.alloc),0)) AS Overdue1,
        Sum(IF ((TO_DAYS(&#039;2018-06-15&#039;) - TO_DAYS(IF (trans.type=20 OR trans.type=21,trans.due_date,trans.tran_date))) &gt; 60,IF (trans.type=20 OR trans.type=2
      OR (trans.type=0 AND (trans.ov_amount + trans.ov_gst + trans.ov_discount)&gt;0), 1, -1)*
            ABS(trans.ov_amount + trans.ov_gst + trans.ov_discount) - trans.alloc),0)) AS Overdue2,
        supp.credit_limit - Sum(IFNULL(IF(trans.type=21, -1, 1) 
            * (ov_amount + ov_gst + ov_discount),0)) as cur_credit,
        supp.tax_group_id</code></pre></div><p>I think the problem is here 4 opening brackets - 5 closing:-<br />\purchasing\includes\db\suppliers_db.inc<br /></p><div class="codebox"><pre><code>94:         $value = &quot;IF (trans.type=&quot;.ST_SUPPINVOICE.&quot; OR trans.type=&quot;.ST_BANKDEPOSIT.&quot;
95:       OR (trans.type=&quot;.ST_JOURNAL.&quot; AND (trans.ov_amount + trans.ov_gst + trans.ov_discount)&gt;0), 1, -1)*
96:             ABS(trans.ov_amount + trans.ov_gst + trans.ov_discount) - trans.alloc)&quot;;</code></pre></div><p>Which makes sense as the OR is called 4 times...</p><p>I cannot find when this was changed...</p><p>From my understanding of the above Line 96 should be:-<br /></p><div class="codebox"><pre><code>96:             ABS(trans.ov_amount + trans.ov_gst + trans.ov_discount) - trans.alloc&quot;;</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (poncho1234)]]></author>
			<pubDate>Fri, 15 Jun 2018 21:54:05 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=31908#p31908</guid>
		</item>
		<item>
			<title><![CDATA[FA2.4.4 Aged Supplier Analysis]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=31906#p31906</link>
			<description><![CDATA[<p>Reports/Suppliers/ Aged Supplier analysis, with the following settings:</p><p>Show alocated = No<br />Summary = No or Yes<br />Suppress Zero&#039;s = Yes or no<br />Graphics = No Graphics.</p><p>Reports deos not display.</p><p>With Show alocated = Yes, Report displays</p><p>Please provide solution.</p><p>Using latest Firefox, other reports do display.</p>]]></description>
			<author><![CDATA[null@example.com (seahawk)]]></author>
			<pubDate>Fri, 15 Jun 2018 21:15:45 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=31906#p31906</guid>
		</item>
	</channel>
</rss>
