Template:QuestionQuery: Difference between revisions
From Karteria DWRP Wiki
Jump to navigationJump to search
No edit summary |
No edit summary |
||
| (35 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
<includeonly>{{#cargo_query:tables=Questions|fields= _pageName = questionPage, trim(QuestionFaqPage)=faqPage,Link = questionLink, Topics__full=questionTopics, AskedBy = questionFrom,DateAnswered=answerDate, DateAsked = askedDate, QuestionText=Question_Text, AnswerText=Answer_Text | <includeonly>{{#ifeq: {{{1|}}} | FAQ Page || {{#ifeq: {{{1|}}} | Topic || {{#ifeq: {{{1|}}} | Question | | ||
|where= {{#ifeq: {{{1|}}}| FAQ Page | {{#arraymap: {{{2|}}}|,|xx| QuestionFaqPage = 'xx' | | |{{#ifeq: {{{1|}}} | Keyword | | ||
{{#ifeq: {{{1|}}} | Topic | {{#arraymap: {{{2|}}}|,|xx| Topics HOLDS 'xx' | | |QuestionQuery error: Supply FAQ Page, Topic, Keyword or Question as first parameter }}}}}}}} | ||
{{#ifeq: {{{1|}}} | Question | {{#arraymap: {{{2|}}}|,|xx| _pageName = 'xx' | | {{#ifexpr: {{#ifeq: {{{1|}}} | FAQ Page | 1 | 0}} or {{#ifeq: {{{1|}}} | Topic | 1 | 0}} or {{#ifeq: {{{1|}}} | Question | 1 | 0}} or {{#ifeq: {{{1|}}} | Keyword | 1 | 0}} | | ||
{{#cargo_query:tables=Questions|fields= _pageName = questionPage, trim(QuestionFaqPage)=faqPage,Link = questionLink, Topics__full=questionTopics, AskedBy = questionFrom,DateAnswered=answerDate, DateAsked = askedDate, QuestionText=Question_Text, AnswerText=Answer_Text | |||
|where= {{#ifeq: {{{1|}}}| FAQ Page | {{#arraymap: {{{2|}}}|,|xx| QuestionFaqPage = 'xx' |\s or \s}} | | |||
{{#ifeq: {{{1|}}} | Topic | {{#arraymap: {{{2|}}}|,|xx| Topics HOLDS 'xx' |\s or \s}}| | |||
{{#ifeq: {{{1|}}} | Question | {{#arraymap: {{{2|}}}|,|xx| _pageName = 'xx' |\s or \s}} | |||
| | |||
{{#ifeq: {{{1|}}} | Keyword | {{#arraymap: {{{2|}}}|,|xx| QuestionText like '%xx%' or AnswerText like '%xx%' |\s or \s}} | |||
}} }} | }} }} | ||
}} | |||
}} | }} | ||
|group by= Questions._pageName, Questions.QuestionFaqPage,Questions.Link, Questions.Topics__full, Questions.AskedBy,Questions.DateAnswered, Questions.DateAsked, Questions.QuestionText, Questions.AnswerText | |group by= Questions._pageName, Questions.QuestionFaqPage,Questions.Link, Questions.Topics__full, Questions.AskedBy,Questions.DateAnswered, Questions.DateAsked, Questions.QuestionText, Questions.AnswerText | ||
| Line 9: | Line 16: | ||
|template=QuestionQueryTableTemplate | |template=QuestionQueryTableTemplate | ||
|delimiter=\n | |delimiter=\n | ||
|intro={{{!}} class="wikitable" | |intro={{{!}} class="wikitable mw-collapsible {{#if: {{{Collapsible|}}}| mw-collapsed}}" | ||
! Information | ! Information | ||
! Question | ! Question | ||
! Answer | ! Answer | ||
| outro={{!}}} | | outro={{!}}} | ||
| offset={{{offset|}}} | |||
| default= ''No results'' | |||
| order by=Questions.DateAnswered desc | |||
}} | }} | ||
}}</includeonly><noinclude>{{/doc}}</noinclude> | |||
Latest revision as of 04:26, 18 January 2026
No description.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| Query type | 1 | no description
| Unknown | required |
| Value | 2 | Limiting value for the query
| Unknown | optional |