SQL
AخA
USE plwiki_p;
SELECT CONCAT(page_title) as page_title
FROM page
JOIN externallinks
ON page_id = el_from
WHERE page_namespace = 0
AND ((el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=999:licencje-dla-mmks-podhale-i-tmh-polonii&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=986:komunikat-po-posiedzeniu-zarzadu-pzhl&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=654:komunikat-zarzadzie-pzhl&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=1004:decyzje-komisji-ds-licencji-klubowych&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=990:kolejne-licencje-klubowe&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=711:opolskie-posiedzenie-zarzadu&catid=7:template&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=697:komunikat&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=724:poslowie-za-liga-zawodowa&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=643:zegnamy-mariana-jezaka&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=367&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=613:drugie-zwyciestwo-polakow&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=466:wygrana-havirov-18&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1462%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1463%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=192:duet-zakharkin-bykow&catid=7:template&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=296:jeszcze-nie-teraz&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/aktualnosci/114-komunikat-phl-w-meczu-nr-123-ekstraklasy%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1173%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=465:rewanz-za-krynice&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=360%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=361%') OR
(el_to LIKE 'http://www.pzhl.org.pl/28,historyczne-ms-w-katowicach-1976r%') OR
(el_to LIKE 'http://www.pzhl.org.pl/aktualnosci/181-odszedl-kazimierz-malysiak%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=584:przegrana-wegrami&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=619:zosta%C5%82a-ostatnia-przeszkoda&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=616:trzeci-mecz-trzecia-wygrana&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=195:pierwszy-trening-zacharkin&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=863:zmarl-birula-bialynicki&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=471:bratankowie-byli-lepsi&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=387&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=638:polski-hokej-ma-sponsora&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/775,komunikat-po-spotkaniu-z-klubami%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=350%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=351%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=359%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=207:polska-pokonala-francje&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=639%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=469:wysokie-zwyciestwo-polski&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=994:cracovia-unia-sanok-z-licencjami&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=369:ukraina-pokonana&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/aktualnosci/144-lista-akredytowanych-puchar-polski-w-nowym-targu%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=982:13klubow-z-licencjami&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=778:powolania-parfenova&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=361:wyrownany-boj-kazachstanem&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=699:zmar-wadysaw-radwa%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=658%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1200%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=291:e-viva-polonia&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=624:awans-ukrainy&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=304%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=303%') OR
(el_to LIKE 'http://www.pzhl.org.pl/1613,stanowisko-pzhl-ws-klubu-ze-lwowa%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=610:dobry-poczatek-polakow&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=1005:terminarz-i-ligi-2014-15&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1456%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1457%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1459%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=287:mocne-otwarcie-polakow&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/800,terminarz-phl-201415%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=893:oswiadczenie-dra-piotra-halasika&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=362%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=675%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=670%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=453%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=229%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=587:2-5-japonia&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/aktualnosci/255-puchar-kontynentalny-znow-w-tychach%') OR
(el_to LIKE 'http://www.pzhl.org.pl/1656,sciana-z-luby%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=265:zgrupowanie-kadry-u18&catid=7:template&Itemid=186&lang=pl%'))
GROUP BY page_title
ORDER BY page_title;
SELECT CONCAT('# ',el_to) as el_to#, COUNT(*) AS counting
FROM page
JOIN externallinks
ON page_id = el_from
WHERE page_namespace = 0
AND ((el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=999:licencje-dla-mmks-podhale-i-tmh-polonii&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=986:komunikat-po-posiedzeniu-zarzadu-pzhl&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=654:komunikat-zarzadzie-pzhl&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=1004:decyzje-komisji-ds-licencji-klubowych&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=990:kolejne-licencje-klubowe&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=711:opolskie-posiedzenie-zarzadu&catid=7:template&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=697:komunikat&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=724:poslowie-za-liga-zawodowa&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=643:zegnamy-mariana-jezaka&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=367&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=613:drugie-zwyciestwo-polakow&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=466:wygrana-havirov-18&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1462%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1463%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=192:duet-zakharkin-bykow&catid=7:template&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=296:jeszcze-nie-teraz&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/aktualnosci/114-komunikat-phl-w-meczu-nr-123-ekstraklasy%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1173%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=465:rewanz-za-krynice&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=360%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=361%') OR
(el_to LIKE 'http://www.pzhl.org.pl/28,historyczne-ms-w-katowicach-1976r%') OR
(el_to LIKE 'http://www.pzhl.org.pl/aktualnosci/181-odszedl-kazimierz-malysiak%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=584:przegrana-wegrami&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=619:zosta%C5%82a-ostatnia-przeszkoda&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=616:trzeci-mecz-trzecia-wygrana&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=195:pierwszy-trening-zacharkin&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=863:zmarl-birula-bialynicki&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=471:bratankowie-byli-lepsi&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=387&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=638:polski-hokej-ma-sponsora&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/775,komunikat-po-spotkaniu-z-klubami%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=350%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=351%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=359%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=207:polska-pokonala-francje&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=639%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=469:wysokie-zwyciestwo-polski&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=994:cracovia-unia-sanok-z-licencjami&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=369:ukraina-pokonana&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/aktualnosci/144-lista-akredytowanych-puchar-polski-w-nowym-targu%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=982:13klubow-z-licencjami&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=778:powolania-parfenova&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=361:wyrownany-boj-kazachstanem&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=699:zmar-wadysaw-radwa%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=658%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1200%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=291:e-viva-polonia&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=624:awans-ukrainy&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=304%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=303%') OR
(el_to LIKE 'http://www.pzhl.org.pl/1613,stanowisko-pzhl-ws-klubu-ze-lwowa%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=610:dobry-poczatek-polakow&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=1005:terminarz-i-ligi-2014-15&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1456%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1457%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=1459%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=287:mocne-otwarcie-polakow&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/800,terminarz-phl-201415%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=893:oswiadczenie-dra-piotra-halasika&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=362%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=675%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=670%') OR
(el_to LIKE 'http://www.pzhl.org.pl/pl/news?id=453%') OR
(el_to LIKE 'http://www.pzhl.org.pl/news.php?readmore=229%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=587:2-5-japonia&catid=7&Itemid=186&lang=pl%') OR
(el_to LIKE 'http://www.pzhl.org.pl/aktualnosci/255-puchar-kontynentalny-znow-w-tychach%') OR
(el_to LIKE 'http://www.pzhl.org.pl/1656,sciana-z-luby%') OR
(el_to LIKE 'http://www.pzhl.org.pl/index.php?option=com_content&view=article&id=265:zgrupowanie-kadry-u18&catid=7:template&Itemid=186&lang=pl%'))
GROUP BY el_to
ORDER BY /*counting DESC,*/ el_to;
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.