User:Electricsheep/sandbox: Difference between revisions

Line 2:
=Cargo query test=
{{#cargo_query:
tables = banners
| fields = Image, Rateup_character=Rateup_character, date_format(Start_date, '%m/%d')=sdate, date_format(End_date, '%m/%d')=edate
| where = End_date > NOW() AND Start_date < DATE_ADD(NOW(), INTERVAL 2 DAY) AND Server="JP"
| order by = Start_date DESC
Line 9:
| template = FrontpageBanner
| named args = yes
}}
 
 
=Cargo query test table output=
{{BannerTable |
{{#cargo_query:
tables = banners
| fields = NameJP, NameEN, Image, Rateup_character=Rateup_character, Limited, Start_date=Start_date, End_date=End_date, Notes
| where = End_date > NOW() AND Start_date < DATE_ADD(NOW(), INTERVAL 2 DAY) AND Server="GL"
| order by = Start_date DESC
| format = template
| template = Banner
| named args = yes
}}
}}