Changes between Version 3 and Version 4 of AdvancedReports
- Timestamp:
- 08/29/26 01:26:13 (2 weeks ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
AdvancedReports
v3 v4 317 317 pending_stats AS ( 318 318 SELECT 319 s.idAS pst_stock_id,320 COUNT(tr.id) AS pst_pending_count319 tr.stock_id AS pst_stock_id, 320 COUNT(tr.id) AS pst_pending_count 321 321 FROM trade_request tr 322 JOIN stock s ON tr.stock_symbol = s.symbol323 322 WHERE tr.status = 'PENDING' 324 GROUP BY s.id323 GROUP BY tr.stock_id 325 324 ) 326 325 … … 417 416 -- ws_active_watchers ← COUNT(DISTINCT w.user_id) (watchlist w) 418 417 419 -- pending_stats = γ s.id;420 -- pst_stock_id ← s.id,418 -- pending_stats = γ tr.stock_id; 419 -- pst_stock_id ← tr.stock_id, 421 420 -- pst_pending_count ← COUNT(tr.id) ( 422 -- σ status = 'PENDING' (trade_request tr) ⋈ trade_stock_symbol = symbol stock s)421 -- σ status = 'PENDING' (trade_request tr) ) 423 422 424 423 π stock_id ← s.id, symbol ← s.symbol, stock_name ← s.name, current_price ← s.current_price,
