start time: Вт. сент. 17 13:59:45 MSK 2013 monetdbd is running spawn mclient -u monetdb -d hits assword: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT UserID, extract (minute from EventTime) AS m, SearchPhrase, count(*) FROM hits_100m GROUP BY UserID, m, SearchPhrase ORDER BY count(*) DESC LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT UserID, extract (minute from EventTime) AS m, SearchPhrase, count(*) FROM hits_100m GROUP BY UserID, m, SearchPhrase ORDER BY count(*) DESC LIMIT 10; \q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT UserID, extract (minute from EventTime) AS m, SearchPhrase, count(*) FROM hits_100m GROUP BY UserID, m, SearchPhrase ORDER BY count(*) DESC LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT UserID, extract (minute from EventTime) AS m, SearchPhrase, count(*) FROM hits_100m GROUP BY UserID, m, SearchPhrase ORDER BY count(*) DESC LIMIT 10; \q +---------------------+------+--------------+------+ +=====================+======+==============+======+ +---------------------+------+--------------+------+ 10 tuples (19m 33s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT UserID, extract (minute from EventTime) AS m, SearchPhrase, count(*) FROM hits_100m GROUP BY UserID, m, SearchPhrase ORDER BY count(*) DESC LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT UserID, extract (minute from EventTime) AS m, SearchPhrase, count(*) FROM hits_100m GROUP BY UserID, m, SearchPhrase ORDER BY count(*) DESC LIMIT 10; \q -- ещё более сложная агрегация, не стоит выполнять на больших таблицах.; monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT UserID FROM hits_100m WHERE UserID = 1234567890; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT UserID FROM hits_100m WHERE UserID = 1234567890; +--------+ +========+ +--------+ 0 tuples (3.9s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT UserID FROM hits_100m WHERE UserID = 1234567890; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT UserID FROM hits_100m WHERE UserID = 1234567890; +--------+ +========+ +--------+ 0 tuples (0.787ms) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT UserID FROM hits_100m WHERE UserID = 1234567890; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT UserID FROM hits_100m WHERE UserID = 1234567890; +--------+ +========+ +--------+ 0 tuples (32.566ms) sql>\q -- мощная фильтрация по столбцу типа UInt64.; monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT count(*) FROM hits_100m WHERE URL LIKE '%metrika%'; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT count(*) FROM hits_100m WHERE URL LIKE '%metrika%'; +------+ +======+ +------+ 1 tuple (27.4s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT count(*) FROM hits_100m WHERE URL LIKE '%metrika%'; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT count(*) FROM hits_100m WHERE URL LIKE '%metrika%'; +------+ +======+ +------+ 1 tuple (1.7s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT count(*) FROM hits_100m WHERE URL LIKE '%metrika%'; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT count(*) FROM hits_100m WHERE URL LIKE '%metrika%'; +------+ +======+ +------+ 1 tuple (2.1s) sql>\q -- фильтрация по поиску подстроки в строке.; monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT SearchPhrase, MAX(URL), count(*) FROM hits_100m WHERE URL LIKE '%metrika%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase, MAX(URL), count(*) FROM hits_100m WHERE URL LIKE '%metrika%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; +---------------------------------------------+----------------------------------------------------------------------------------------------------------+------+ +=============================================+==========================================================================================================+======+ +---------------------------------------------+----------------------------------------------------------------------------------------------------------+------+ 10 tuples (4.0s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT SearchPhrase, MAX(URL), count(*) FROM hits_100m WHERE URL LIKE '%metrika%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase, MAX(URL), count(*) FROM hits_100m WHERE URL LIKE '%metrika%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; +---------------------------------------------+----------------------------------------------------------------------------------------------------------+------+ +=============================================+==========================================================================================================+======+ +---------------------------------------------+----------------------------------------------------------------------------------------------------------+------+ 10 tuples (2.6s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT SearchPhrase, MAX(URL), count(*) FROM hits_100m WHERE URL LIKE '%metrika%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase, MAX(URL), count(*) FROM hits_100m WHERE URL LIKE '%metrika%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; +---------------------------------------------+----------------------------------------------------------------------------------------------------------+------+ +=============================================+==========================================================================================================+======+ +---------------------------------------------+----------------------------------------------------------------------------------------------------------+------+ 10 tuples (2.6s) sql>\q -- вынимаем большие столбцы, фильтрация по строке.; monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT SearchPhrase, MAX(URL), MAX(Title), count(*) AS c, count(DISTINCT UserID) FROM hits_100m WHERE Title LIKE '%Яндекс%' AND URL <> '%.yandex.%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase, MAX(URL), MAX(Title), count(*) AS c, count(DISTINCT UserID) FROM hits_100m WHERE Title LIKE '%Яндекс%' AND URL <> '%.yandex.%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; \q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT SearchPhrase, MAX(URL), MAX(Title), count(*) AS c, count(DISTINCT UserID) FROM hits_100m WHERE Title LIKE '%Яндекс%' AND URL <> '%.yandex.%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase, MAX(URL), MAX(Title), count(*) AS c, count(DISTINCT UserID) FROM hits_100m WHERE Title LIKE '%Яндекс%' AND URL <> '%.yandex.%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; \q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT SearchPhrase, MAX(URL), MAX(Title), count(*) AS c, count(DISTINCT UserID) FROM hits_100m WHERE Title LIKE '%Яндекс%' AND URL <> '%.yandex.%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase, MAX(URL), MAX(Title), count(*) AS c, count(DISTINCT UserID) FROM hits_100m WHERE Title LIKE '%Яндекс%' AND URL <> '%.yandex.%' AND SearchPhrase <> '' GROUP BY SearchPhrase ORDER BY count(*) DESC LIMIT 10; \q -- чуть больше столбцы.; monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT * FROM hits_100m WHERE URL LIKE '%metrika%' ORDER BY EventTime LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT * FROM hits_100m WHERE URL LIKE '%metrika%' ORDER BY EventTime LIMIT 10; \q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT * FROM hits_100m WHERE URL LIKE '%metrika%' ORDER BY EventTime LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT * FROM hits_100m WHERE URL LIKE '%metrika%' ORDER BY EventTime LIMIT 10; \q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT * FROM hits_100m WHERE URL LIKE '%metrika%' ORDER BY EventTime LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT * FROM hits_100m WHERE URL LIKE '%metrika%' ORDER BY EventTime LIMIT 10; +---------------------+------+------------+------+------------+------------+-------+------------+------+---------------------+------+------+------+-------------+------+ : : enab : : even : : : erid : : onid : : terc : : agen : : rer :> : : le : : t : : : : : : : lass : : t : : :> +=====================+======+============+======+============+============+=======+============+======+=====================+======+======+======+=============+======+ : : : льная пост : : 09:07:16. : : : : : : : : : ru/blog/pro : : : : : ановка ц...> : 000000 : : : : : : : : : motion/se...> : : : : : : 09:07:31. : : : : : : : : : ru/blog/pro : : : : : : : 000000 : : : : : : : : : motion/se...> : : : : льная пост : : 09:21:03. : : : : : : : : : ru/blog/pro : : : : : ановка ц...> : 000000 : : : : : : : : : motion/se...> : : : : : : 09:21:23. : : : : : : : : : ru/blog/pro : : : : : : : 000000 : : : : : : : : : motion/se...> : : : : льная пост : : 11:17:13. : : : : : : : : : ru/blog/pro : : : : : ановка ц...> : 000000 : : : : : : : : : motion/se...> : : : : : : 11:17:24. : : : : : : : : : ru/blog/pro : : : : : : : 000000 : : : : : : : : : motion/se...> : : : : льная пост : : 12:50:56. : : : : : : : : : ru/blog/pro : : : : : ановка ц...> : 000000 : : : : : : : : : motion/se...> : : : : : : 12:51:11. : : : : : : : : : ru/blog/pro : : : : : : : 000000 : : : : : : : : : motion/se...> : : : : льная пост : : 13:23:20. : : : : : : : : : ru/blog/pro : : : : : ановка ц...> : 000000 : : : : : : : : : motion/se...> : : : : : : 13:23:35. : : : : : : : : : ru/blog/pro : : : : : : : 000000 : : : : : : : : : motion/se...> : +---------------------+------+------------+------+------------+------------+-------+------------+------+---------------------+------+------+------+-------------+------+ 10 tuples (3m 29s) !91 columns dropped, 15 fields truncated! note: to disable dropping columns and/or truncating fields use \w-1 sql>\q -- плохой запрос - вынимаем все столбцы.; monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime LIMIT 10; +-------------------------------------------------+ +=================================================+ +-------------------------------------------------+ 10 tuples (10.5s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime LIMIT 10; +-------------------------------------------------+ +=================================================+ +-------------------------------------------------+ 10 tuples (5.7s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime LIMIT 10; +-------------------------------------------------+ +=================================================+ +-------------------------------------------------+ 10 tuples (40.9s) sql>\q -- большая сортировка.; monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY SearchPhrase LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY SearchPhrase LIMIT 10; +------------------------------------------------------------------------+ +========================================================================+ +------------------------------------------------------------------------+ 10 tuples (4.8s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY SearchPhrase LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY SearchPhrase LIMIT 10; +------------------------------------------------------------------------+ +========================================================================+ +------------------------------------------------------------------------+ 10 tuples (4.7s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY SearchPhrase LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY SearchPhrase LIMIT 10; +------------------------------------------------------------------------+ +========================================================================+ +------------------------------------------------------------------------+ 10 tuples (4.7s) sql>\q -- большая сортировка по строкам.; monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime, SearchPhrase LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime, SearchPhrase LIMIT 10; +-------------------------------------------------+ +=================================================+ +-------------------------------------------------+ 10 tuples (1m 25s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime, SearchPhrase LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime, SearchPhrase LIMIT 10; +-------------------------------------------------+ +=================================================+ +-------------------------------------------------+ 10 tuples (4.7s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime, SearchPhrase LIMIT 10; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SearchPhrase FROM hits_100m WHERE SearchPhrase <> '' ORDER BY EventTime, SearchPhrase LIMIT 10; +-------------------------------------------------+ +=================================================+ +-------------------------------------------------+ 10 tuples (5.7s) sql>\q -- большая сортировка по кортежу.; monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 1 query: SELECT CounterID, avg(length(URL)) AS l, count(*) FROM hits_100m WHERE URL <> '' GROUP BY CounterID HAVING count(*) > 100000 ORDER BY l DESC LIMIT 25; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT CounterID, avg(length(URL)) AS l, count(*) FROM hits_100m WHERE URL <> '' GROUP BY CounterID HAVING count(*) > 100000 ORDER BY l DESC LIMIT 25; +-----------+--------------------------+---------+ +===========+==========================+=========+ +-----------+--------------------------+---------+ 25 tuples (52.4s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT CounterID, avg(length(URL)) AS l, count(*) FROM hits_100m WHERE URL <> '' GROUP BY CounterID HAVING count(*) > 100000 ORDER BY l DESC LIMIT 25; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT CounterID, avg(length(URL)) AS l, count(*) FROM hits_100m WHERE URL <> '' GROUP BY CounterID HAVING count(*) > 100000 ORDER BY l DESC LIMIT 25; +-----------+--------------------------+---------+ +===========+==========================+=========+ +-----------+--------------------------+---------+ 25 tuples (30.3s) sql>\q monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT CounterID, avg(length(URL)) AS l, count(*) FROM hits_100m WHERE URL <> '' GROUP BY CounterID HAVING count(*) > 100000 ORDER BY l DESC LIMIT 25; spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT CounterID, avg(length(URL)) AS l, count(*) FROM hits_100m WHERE URL <> '' GROUP BY CounterID HAVING count(*) > 100000 ORDER BY l DESC LIMIT 25; +-----------+--------------------------+---------+ +===========+==========================+=========+ +-----------+--------------------------+---------+ 25 tuples (29.1s) sql>\q -- считаем средние длины URL для крупных счётчиков.; monetdbd is running spawn mclient -u monetdb -d hits password: could not connect to localhost:50000: Connection refused restart server: /etc/init.d/monetdb5-sql restart monetdbd not running. Starting MonetDB SQL server: monetdbd. times: 1 query: SELECT SUBSTRING( SUBSTRING(Referer, POSITION('//' IN Referer) + 2), 1, ifthenelse( (0 > POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1), 0, POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1 ) ) spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SUBSTRING( SUBSTRING(Referer, POSITION('//' IN Referer) + 2), 1, ifthenelse( (0 > POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1), 0, POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1 ) ) more>monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 2 query: SELECT SUBSTRING( SUBSTRING(Referer, POSITION('//' IN Referer) + 2), 1, ifthenelse( (0 > POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1), 0, POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1 ) ) spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SUBSTRING( SUBSTRING(Referer, POSITION('//' IN Referer) + 2), 1, ifthenelse( (0 > POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1), 0, POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1 ) ) more>monetdbd is running spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql> sql>\q times: 3 query: SELECT SUBSTRING( SUBSTRING(Referer, POSITION('//' IN Referer) + 2), 1, ifthenelse( (0 > POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1), 0, POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1 ) ) spawn mclient -u monetdb -d hits password: Welcome to mclient, the MonetDB/SQL interactive terminal (Feb2013-SP3) Database: MonetDB v11.15.11 (Feb2013-SP3), 'mapi:monetdb://mturlrep13:50000/hits' Type \q to quit, \? for a list of available commands auto commit mode: on sql>SELECT SUBSTRING( SUBSTRING(Referer, POSITION('//' IN Referer) + 2), 1, ifthenelse( (0 > POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1), 0, POSITION('/' IN SUBSTRING(Referer, POSITION('//' IN Referer) + 2)) - 1 ) ) more>