Fork of zhwiki: redirect from wp to wpj by Xiplus
This query is marked as a draft This query has been published by Xiplus.

SQL

AخA
 
USE zhwiki_p;
SELECT CONCAT("[[{{subst:ns:", page_namespace, "}}:", page_title, "]]") AS "from", CONCAT("[[{{subst:ns:", rd_namespace, "}}:", rd_title, "]]") AS "to"
FROM (
  SELECT * FROM redirect
  WHERE rd_namespace = 4
) rd
LEFT JOIN page ON rd_from = page_id
WHERE page_namespace = 102
By running queries you agree to the Cloud Services Terms of Use and you irrevocably agree to release your SQL under CC0 License.
All SQL code is licensed under CC0 License.

Checking query status...