Re: problem downloading (Templatetiger)

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: problem downloading (Templatetiger)

Kolossos-2
>
> Tim Landscheidt wrote:
> File a request according to
> <URI:https://wiki.toolserver.org/view/Query_service> with
> the SQL query at the top of Templatetiger's page minus the
> LIMIT clause and ask for it to be run on u_kolossos_p.
>
> Tim
>  
This SQL-command is only the first (simple) part of the SQL query the
result is used to generate the second (long) part (Reason: performance
bug in MYSQL).
Everybody with toolserver account can connect the database u_kolossos_p.
And could create such a like this for persondata :

SELECT DISTINCT `name` a,
(SELECT `Value` FROM `pub_tt1_de` WHERE `entry_name` LIKE 'ALTERNATIVNAMEN' AND `tp_name` LIKE 'Personendaten' AND `name` = a LIMIT 1 ) ALTERNATIVNAMEN,
(SELECT `Value` FROM `pub_tt1_de` WHERE `entry_name` LIKE 'KURZBESCHREIBUNG' AND `tp_name` LIKE 'Personendaten' AND `name` = a LIMIT 1) KURZBESCHREIBUNG,
(SELECT `Value` FROM `pub_tt1_de` WHERE `entry_name` LIKE 'GEBURTSDATUM' AND `tp_name` LIKE 'Personendaten' AND `name` = a LIMIT 1) GEBURTSDATUM,
(SELECT `Value` FROM `pub_tt1_de` WHERE `entry_name` LIKE 'GEBURTSORT' AND `tp_name` LIKE 'Personendaten' AND `name` = a LIMIT 1 ) GEBURTSORT,
(SELECT `Value`FROM `pub_tt1_de` WHERE `entry_name` LIKE 'STERBEDATUM' AND `tp_name` LIKE 'Personendaten' AND `name` = a LIMIT 1) STERBEDATUM,
(SELECT `Value` FROM `pub_tt1_de` WHERE `entry_name` LIKE 'STERBEORT' AND `tp_name` LIKE 'Personendaten' AND `name` = a LIMIT 1) STERBEORT,
(SELECT `Value` FROM `pub_tt1_de` WHERE `tp_name` LIKE 'PND' AND `name` = a LIMIT 1) PND
FROM `pub_tt1_de` WHERE `tp_name` LIKE 'Personendaten'


Also Query_service would be possible for a query like this. Or you use
the files of sk or request an own account. To allow the query without a
limit from web-interface seems not usefull. We have templates which are
used over 100.000 times.

Greetings Kolossos





_______________________________________________
Toolserver-l mailing list ([hidden email])
https://lists.wikimedia.org/mailman/listinfo/toolserver-l
Posting guidelines for this list: https://wiki.toolserver.org/view/Mailing_list_etiquette
Reply | Threaded
Open this post in threaded view
|

Re: problem downloading (Templatetiger)

Daniel Schwen-2
Just out of curiosity, why are you using LIKE even though you do not
have any wildcards in your match string? Wouldn't = do the same? Or is
MySQL optimizing so that it doesn't make a difference?

> (SELECT `Value` FROM `pub_tt1_de` WHERE `entry_name` LIKE 'ALTERNATIVNAMEN' AND `tp_name` LIKE 'Personendaten' AND `name` = a LIMIT 1   ) ALTERNATIVNAMEN,

_______________________________________________
Toolserver-l mailing list ([hidden email])
https://lists.wikimedia.org/mailman/listinfo/toolserver-l
Posting guidelines for this list: https://wiki.toolserver.org/view/Mailing_list_etiquette
Reply | Threaded
Open this post in threaded view
|

problem downloading (Templatetiger)

Kolossos-2
In reply to this post by Kolossos-2
Dschwen wrote:

   why are you using LIKE even though you do not
   have any wildcards in your match string?
   
I was wrong and believe that LIKE is case insensitive and "=" is case
sensitive, but both are case insensitive.
So "=" seems better also if the difference is probably not so great.

Kolossos

_______________________________________________
Toolserver-l mailing list ([hidden email])
https://lists.wikimedia.org/mailman/listinfo/toolserver-l
Posting guidelines for this list: https://wiki.toolserver.org/view/Mailing_list_etiquette