SET NAMES cp1251
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


SELECT * FROM lect_url WHERE is_visible=1 ORDER BY date_created DESC LIMIT 0,3 
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


select distinct year(date_created)+0.01*month(date_created) as ym from lect_url order by ym desc limit 0,6
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


select count(id) as n_urls, sum(n_visits) as n_visits from lect_url
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


SELECT * FROM lect_url WHERE is_visible=1 ORDER BY date_created DESC LIMIT 0,3 
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


select distinct year(date_created)+0.01*month(date_created) as ym from lect_url order by ym desc limit 0,6
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


DROP TABLE IF EXISTS `query_cache`;
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


CREATE TEMPORARY TABLE `query_cache` (
  `session_id` varchar(32) default '0',
  `url_id` bigint(20) NOT NULL default '0',
  `weight` int(11) NOT NULL default '0',
  `is_required` int(11) NOT NULL default '0',
  KEY `session_id` (`session_id`),
  KEY `url_id` (`url_id`),
  KEY `weight` (`weight`)
) ENGINE=MEMORY DEFAULT CHARSET=cp1251;
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


INSERT INTO query_cache(session_id, url_id, weight)    SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,1 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Забіла', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,2 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Наталя', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,3 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Шевченко', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,4 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Тарас', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,5 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Нестайко', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,6 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Всеволод', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,7 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Татарська', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,8 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('народна', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,9 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('казка', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,10 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Стеценко', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,11 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Микола', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,12 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Стельмах', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,13 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Ярослав', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,14 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Мень', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,15 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Олександр', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,16 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Пінковська', u.author )>0)
                                    AND u.is_visible=1   UNION SELECT DISTINCT '15a7a65a262e4a77cd0d8209ea697415',u.id,17 as weight
                                  FROM lect_url AS u
                                  WHERE (LOCATE('Мирослава', u.author )>0)
                                    AND u.is_visible=1  
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


SELECT SQL_CALC_FOUND_ROWS
                   u.*
                 , count(c.weight) as relev
            from query_cache as c
               , lect_url AS u
            where u.id=c.url_id
              AND c.session_id='15a7a65a262e4a77cd0d8209ea697415'
               AND  u.is_visible=1 
            group by u.id
            having relev=17
            order by u.date_created  desc
            LIMIT 0,10
    
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


select count(id) as n_comments, url_id from lect_url_comment where url_id IN (0) group by url_id
Lost connection to MySQL server at 'reading initial communication packet', system error: 111


SELECT * FROM lect_static_menu ORDER BY ordering
Lost connection to MySQL server at 'reading initial communication packet', system error: 111

Читанка

Автор: Забіла Наталя, Шевченко Тарас, Нестайко Всеволод, Татарська народна казка, Стеценко Микола, Стельмах Ярослав, Мень Олександр, Пінковська Мирослава

Нічого не знайдено



Читанка © 2009
Дизайн Fish,
програмування Dobrovolsky