Data semantics: the missing layer of your data warehouse

Coinbase
SELECT 
COUNT(*)
, DATE_TRUNC(‘month’, timestamp)
FROM facts.trades
WHERE asset = ‘BTC
GROUP BY 2
SELECT 
SUM(amount) AS volume
, DATE_TRUNC(‘month’, timestamp)
FROM facts.trades
WHERE asset = ‘ETH
GROUP BY 2
compute: sqlstorage: facts.trades 
measures:
— name: trade_volume
kind: sum
— name: trades
kind: count
dimensions:
— name: asset
kind: string
— name: timestamp
kind: time
measures: trades 
dimensions: month
filters: [asset=BTC]
measures: trade_volume 
dimensions: month
filters: [asset=ETH]

The post appeared first on The Coinbase Blog

Buy Bitcoin with Credit Card

BitMex Leverage Trading

Automated Trading Bot

Related Posts

Leave a Reply

Bitcoin (BTC) $ 97,424.10 1.40%
Ethereum (ETH) $ 3,330.57 2.79%
Tether (USDT) $ 1.00 0.00%
Solana (SOL) $ 247.83 4.47%
BNB (BNB) $ 652.93 2.72%
XRP (XRP) $ 1.37 11.67%
Dogecoin (DOGE) $ 0.418106 11.33%
USDC (USDC) $ 1.00 0.06%
Cardano (ADA) $ 1.00 8.75%
Lido Staked Ether (STETH) $ 3,331.35 3.18%