Skip to content

Instantly share code, notes, and snippets.

View toddlipcon's full-sized avatar

Todd Lipcon toddlipcon

View GitHub Profile
select substr(r_reason_desc,1,20)
,avg(ws_quantity)
,avg(wr_refunded_cash)
,avg(wr_fee)
from web_sales, web_returns, web_page, customer_demographics cd1,
customer_demographics cd2, customer_address, date_dim, reason
where ws_web_page_sk = wp_web_page_sk
and ws_item_sk = wr_item_sk
and ws_order_number = wr_order_number
and ws_sold_date_sk = d_date_sk and d_year = 1998
WITH t2 AS
(SELECT `ca_address_sk`,
`ca_state` IN ('CO',
'IL',
'MN') AS `IN`,
`ca_state` IN ('OH',
'MT',
'NM') AS `IN2`,
`ca_state` IN ('TX',
'MO',
with rewrite_dd as
(select d_date_sk from date_dim where
d_date in (select d_date
from date_dim
where d_week_seq in (select d_week_seq
from date_dim
where d_date = '2000-05-18')))
, ss_items as
(select i_item_id item_id
,sum(ss_ext_sales_price) ss_item_rev
with rw_date as (
select * from date_dim where
d_date in (select d_date
from date_dim
where d_week_seq in
(select d_week_seq
from date_dim
where d_date in ('2000-01-24','2000-10-20','2000-11-05'))))
, sr_items as
(select i_item_id item_id,
with dd as (
select d.d_date_sk
from date_dim d
where d.d_month_seq in (select distinct (d_month_seq) from date_dim where d_year = 2002 and d_moy = 1 )
)
select /* TPC-DS Q06 Original*/
a.ca_state state,
count(*) cnt
from
store_sales s ,
with rewrite_dd as
(select d_date_sk from date_dim where
d_date in (select d_date
from date_dim
where d_week_seq in (select d_week_seq
from date_dim
where d_date = '2000-05-18')))
, ss_items as
(select i_item_id item_id
,sum(ss_ext_sales_price) ss_item_rev
[todd@va1026 ~]$ curl -k -s 'https://vc1505.halxg.cloudera.com:25000/krpc' | grep -e remote_ip -e bytes_per_ | perl -e 'while (!eof(STDIN)) { $x = <>; $y = <>; chomp $x; print "$x$y"; }' | sort | grep 27000 | perl -p -e 's,10\.17[^:]*,$x = `getent hosts $& | cut -f2`; chomp $x; $x,ge;'
"remote_ip": "10.17.187.36 va1026.halxg.cloudera.com:27000", "send_bytes_per_sec": 6814117
"remote_ip": "10.17.187.37 va1027.halxg.cloudera.com:27000", "send_bytes_per_sec": 13128533
"remote_ip": "10.17.187.38 va1028.halxg.cloudera.com:27000", "send_bytes_per_sec": 13128533
"remote_ip": "10.17.187.39 va1029.halxg.cloudera.com:27000", "send_bytes_per_sec": 13128533
"remote_ip": "10.17.187.40 va1030.halxg.cloudera.com:27000", "send_bytes_per_sec": 17762133
"remote_ip": "10.17.187.41 va1031.halxg.cloudera.com:27000",
[todd@va1026 ~]$ curl -k -s 'https://vc1505.halxg.cloudera.com:25000/krpc' | grep -e remote_ip -e bytes_per_ | perl -e 'while (!eof(STDIN)) { $x = <>; $y = <>; chomp $x; print "$x$y"; }' | sort | grep 27000
"remote_ip": "10.17.187.36:27000", "send_bytes_per_sec": 3861333
"remote_ip": "10.17.187.37:27000", "send_bytes_per_sec": 23168000
"remote_ip": "10.17.187.38:27000", "send_bytes_per_sec": 24712533
"remote_ip": "10.17.187.39:27000", "send_bytes_per_sec": 20078933
"remote_ip": "10.17.187.40:27000", "send_bytes_per_sec": 22395733
"remote_ip": "10.17.187.41:27000", "send_bytes_per_sec": 23168000
"remote_ip": "10.17.187.42:27000", "send_bytes_per_sec": 26257066
"remote_ip": "10.17.187.43:27000", "send_bytes_per_sec": 22395733
Thread 443 (Thread 0x7f2d91dfb700 (LWP 79173)):
#0 0x00007f2fcf5776d5 in pthread_cond_wait@@GLIBC_2.3.2 () from /lib64/libpthread.so.0
#1 0x000000000193c08b in impala::ConditionVariable::Wait (this=0x41ab67c0, lock=...) at be/src/util/condition-variable.h:51
#2 0x000000000326f8c4 in impala::BlockingQueue<std::unique_ptr<impala::RowBatch, std::default_delete<impala::RowBatch> >, impala::RowBatchBytesFn>::BlockingGet (this=0x41ab6680, out=0x7f2d91df8830) at be/src/util/blocking-queue.h:102
#3 0x000000000326ec8c in impala::RowBatchQueue::GetBatch (this=0x41ab6680) at be/src/runtime/row-batch-queue.cc:42
#4 0x00000000021459a8 in impala::HdfsScanNode::GetNextInternal (this=0x3a3f3800, state=0x7f2db47024e0, row_batch=0x7f2e88f8ad00, eos=0x25ed2211) at be/src/exec/hdfs-scan-node.cc:128
#5 0x00000000021454ca in impala::HdfsScanNode::GetNext (this=0x3a3f3800, state=0x7f2db47024e0, row_batch=0x7f2e88f8ad00, eos=0x25ed2211) at be/src/exec/hdfs-scan-node.cc:106
#6 0x0000000002eb7812 in impala::PartitionedHashJoinN
class_loader classes bytes parent_loader alive? type
<bootstrap> 2293 12872560 null live <internal>
0x000000042cf33368 1 1912 0x000000042ac45d00 dead sun/reflect/DelegatingClassLoader@0x0000000425a50b50
0x000000042c88e658 1 3144 0x000000042ac45d00 dead sun/reflect/DelegatingClassLoader@0x0000000425a50b50
0x00000004336b6ac0 1 3056 0x000000042ac45d00 dead sun/reflect/DelegatingClassLoader@0x0000000425a50b50
0x0000000433689020 1 3064 0x000000042ac45d00 dead sun/reflect/DelegatingClassLoader@0x0000000425a50b50
0x000000042c88e6d8 1 1968 0x000000042ac45d00 dead sun/reflect/DelegatingClassLoader@0x0000000425a50b50
0x000000042d42af88 1 3272 0x000000042ac45d00 dead sun/reflect/DelegatingClassLoader@0x0000000425a50b50
0x000000043c1a2b30 1 3056 null dead sun/reflect/DelegatingClassLoader@0x0000000425a50b50