<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><br class="Apple-interchange-newline"><blockquote type="cite"><div>I found Nicole's report in the SQL library for "Patrons with fines".<br><br>I modified it to allow our libraries to choose their "branch".<br><br>But it doesn't seem to run.<br><br>Can someone show me where the problem is, please?<br><br>Kathy<br>-----------------------------------<br><br>SELECT<br> &nbsp;&nbsp;borrowers.cardnumber,<br> &nbsp;&nbsp;borrowers.surname,<br> &nbsp;&nbsp;borrowers.firstname,<br> &nbsp;&nbsp;FORMAT(SUM(accountlines.amountoutstanding),2) AS due<br>FROM<br> &nbsp;&nbsp;borrowers<br>LEFT JOIN<br> &nbsp;&nbsp;accountlines<br>ON<br> &nbsp;&nbsp;(borrowers.borrowernumber=accountlines.borrowernumber)<br>WHERE<br> &nbsp;&nbsp;accountlines.amountoutstanding &gt; 0 AND borrowers.branchcode='__BRANCHCODE__'<br>GROUP BY borrowers.cardnumber<br>ORDER BY borrowers.surname ASC<br>Kathleen D. Rippel<br>Dept. Head/Consultant--Resource Sharing and Access ;<br>Pathfinder Central (Manager)<br>Central Kansas Library System<br>1409 Williams<br>Great Bend, KS 67530<br><br>(620-792-4865) phone<br>(800-362-2642) toll-free, KS<br>(620-792-5495) fax<br><br><a href="mailto:kdr@ckls.org">kdr@ckls.org</a><br>********************************************************************************************<br>I'm currently reading: This fatal writ, by Sara Woods.<br>I'm currently listening to: The passage, by Justin Cronin. &nbsp;<br><br>_______________________________________________<br>Koha mailing list &nbsp;<a href="http://koha-community.org">http://koha-community.org</a><br><a href="mailto:Koha@lists.katipo.co.nz">Koha@lists.katipo.co.nz</a><br>http://lists.katipo.co.nz/mailman/listinfo/koha<br></div></blockquote><br>In 3.2 the parameters are defined like this:</div><div><br></div><div>&lt;&lt;Select your branch|branches&gt;&gt;</div><div><br></div><div>So instead of:&nbsp;'__BRANCHCODE__'</div><div><br></div><div>Use the&nbsp;&lt;&lt;Select your branch|branches&gt;&gt; and it should work. :)</div><div><br></div><div>The complete how-to is in the manual:&nbsp;<a href="http://koha-community.org/documentation/3-2-manual/?ch=x15127#runtimefaq">http://koha-community.org/documentation/3-2-manual/?ch=x15127#runtimefaq</a></div><div><br></div><div>Liz Rea</div><div>NEKLS</div><div><br></div><div><br></div><div><br></div><div>SELECT<br>&nbsp;&nbsp;borrowers.cardnumber,<br>&nbsp;&nbsp;borrowers.surname,<br>&nbsp;&nbsp;borrowers.firstname,<br>&nbsp;&nbsp;FORMAT(SUM(accountlines.amountoutstanding),2) AS due<br>FROM<br>&nbsp;&nbsp;borrowers<br>LEFT JOIN<br>&nbsp;&nbsp;accountlines<br>ON<br>&nbsp;&nbsp;(borrowers.borrowernumber=accountlines.borrowernumber)<br>WHERE<br>&nbsp;&nbsp;accountlines.amountoutstanding &gt; 0 AND borrowers.branchcode=&lt;&lt;Select your branch|branches&gt;&gt;<br>GROUP BY borrowers.cardnumber<br>ORDER BY borrowers.surname ASC</div><br></body></html>