> Template:Historical harvest fields for - MediaWiki

Template:Historical harvest fields for

From MediaWiki

(Difference between revisions)
Jump to: navigation, search
(add 2017)
(added Average field)
Line 25: Line 25:
     FORMAT(SUM(CASE WHEN YEAR(harvest.date)='2016' AND MONTH(harvest.date)='{{{1}}}' THEN harvest.quantity ELSE NULL END), 2) AS `<a href="/wiki/2016-{{{1}}}_harvest">2016-{{{1}}}</a>`,
     FORMAT(SUM(CASE WHEN YEAR(harvest.date)='2016' AND MONTH(harvest.date)='{{{1}}}' THEN harvest.quantity ELSE NULL END), 2) AS `<a href="/wiki/2016-{{{1}}}_harvest">2016-{{{1}}}</a>`,
     FORMAT(SUM(CASE WHEN YEAR(harvest.date)='2017' AND MONTH(harvest.date)='{{{1}}}' THEN harvest.quantity ELSE NULL END), 2) AS `<a href="/wiki/2017-{{{1}}}_harvest">2017-{{{1}}}</a>`,
     FORMAT(SUM(CASE WHEN YEAR(harvest.date)='2017' AND MONTH(harvest.date)='{{{1}}}' THEN harvest.quantity ELSE NULL END), 2) AS `<a href="/wiki/2017-{{{1}}}_harvest">2017-{{{1}}}</a>`,
 +
    FORMAT(AVG(harvest.quantity), 2) AS `Average`,
     harvest.units AS Units
     harvest.units AS Units
FROM
FROM
     s_product_harvest harvest</includeonly>
     s_product_harvest harvest</includeonly>

Revision as of 05:40, 13 February 2017

Usage

This template is used to provide the fields in the various tables on the monthly historical harvest pages. They are collected here in the interest of easily adding new years, or changing the basic format and information. This template is unlikely to be useful in any other way.

Parameters

  1. two-digit number of the month to be summarized, such as '03' for March.

Bugs

Example

See Also

Template

Share your opinion


blog comments powered by Disqus
Personal tools
Get our newsletter!
Name:
Email Address:

disturbance
entry points
help (off site)
Powered by Mac OS X Powered by Mac MediaWiki Powered by MariaDB Powered by Valentina Studio Pro