Difference between revisions of "GetCompanyDates"
From Sega Retro
(DPL is too slow) |
|||
Line 1: | Line 1: | ||
− | <includeonly><div style="display:none;">{{# | + | <includeonly><div style="display:none;">{{#cargo_query: |
− | | | + | table=companydetails |
− | | | + | |fields=start,end |
− | | | + | |where=company="{{delink|{{{1|}}}}}" |
− | | | + | |limit=1 |
− | | | + | |default= |
− | | | + | |more results text= |
− | }} | + | |format=template |
− | + | |template=GetCompanyDates/Cargo | |
− | + | }} | |
{{#ifexpr:{{#len:{{#var:companystartdate}}}} < 10|{{#vardefine:companystartdate|{{#var:companystartdate}}-01}}|}} | {{#ifexpr:{{#len:{{#var:companystartdate}}}} < 10|{{#vardefine:companystartdate|{{#var:companystartdate}}-01}}|}} | ||
{{#ifexpr:{{#len:{{#var:companystartdate}}}} < 10|{{#vardefine:companystartdate|{{#var:companystartdate}}-01}}|}} | {{#ifexpr:{{#len:{{#var:companystartdate}}}} < 10|{{#vardefine:companystartdate|{{#var:companystartdate}}-01}}|}} |
Latest revision as of 07:02, 30 July 2022
Get start and end dates of a company - store in #var:companystartdate and #var:companyenddate
Examples
{{GetCompanyDates|Sega AM1}} {{#var:companystartdate}} {{#var:companyenddate}}
1992-01-01 1999-05-11