Difference between revisions of "Template:StellarDataQuery"

From Traveller Wiki - Science-Fiction Adventure in the Far future
Jump to navigation Jump to search
Line 9: Line 9:
 
   CONCAT('{{#replace:{{{Non-canon trade codes|}}}|'|''}}')=NCcodes,
 
   CONCAT('{{#replace:{{{Non-canon trade codes|}}}|'|''}}')=NCcodes,
 
   CONCAT('{{#replace:{{{First Survey name|}}}|'|''}}')=FSName,
 
   CONCAT('{{#replace:{{{First Survey name|}}}|'|''}}')=FSName,
   CONCAT('{{#replace:{{{Nahuatl name|}}}|'|''}}')=NSName
+
   CONCAT('{{#replace:{{{Nahuatl name|}}}|'|''}}')=NSName,
 +
  IF(LENGTH(TradeSummary.category)>0, CONCAT('[[',TradeSummary.category,']]'),' '))
 
  |where=StellarData.world="{{#titleparts: {{PAGENAME}}}}" {{#if:{{{era|}}}| AND era = CONCAT('{{#replace:{{{era}}}|'|''}}')}}
 
  |where=StellarData.world="{{#titleparts: {{PAGENAME}}}}" {{#if:{{{era|}}}| AND era = CONCAT('{{#replace:{{{era}}}|'|''}}')}}
 
  |order by=FIELD(era, 'Milieu 1116', 'Milieu 0', 'Second Survey', 'New Era')
 
  |order by=FIELD(era, 'Milieu 1116', 'Milieu 0', 'Second Survey', 'New Era')

Revision as of 18:42, 7 February 2021

You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ') AS `category)>0, CONCAT('',TradeSummary.category,''),' '))` FROM `mw_c...' at line 1

This is a Cargo query template. This template queries data from the StellarData table. The data for this table is entered by using the Template:StellarData.

The query on this template uses Template: StellarData.layout to format the raw data into a page layout form.

Parameters:

  • Name: Full Template: World template for the name of the world
  • Non-canon trade codes: Any trade codes that are not part of the canon T5SS codes
  • First Survey name: Name of the world from the first survey.
  • Nahuatl name : Nahuatl name of the world for the Amec Trade Protectorate.
  • era : name of the era to be selected