explain.depesz.com

PostgreSQL's explain analyze made readable

Result: PX0

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Sort (cost=1,423,458.43..1,423,458.43 rows=1 width=316) (actual rows= loops=)

  • Sort Key: NVL(GJXFJYW.PCK.XFJZT, 99), CASE WHEN ((CAST((GJXFJYW.PCK.WTSDDM) AS TEXT) ~~ '11%') AND (CAST((GJXFJYW.PCK.ZZDM) AS TEXT) ~~ '11%') AND (GJXFJYW.PCK.XM = '郭威') AND (GJXFJYW.PCK.SFZH = '110101195512153052')) THEN 1 WHEN ((CAST((GJXFJYW.PCK.WTSDDM) AS TEXT) ~~ '11%') AND (GJXFJYW.PCK.SFZH = '110101195512153052') AND (GJXFJYW.PCK.XM = '郭威')) THEN 2 WHEN ((CAST((GJXFJYW.PCK.ZZDM) AS TEXT) ~~ '11%') AND (GJXFJYW.PCK.SFZH = '110101195512153052') AND (GJXFJYW.PCK.XM = '郭威')) THEN 3 WHEN ((GJXFJYW.PCK.SFZH = '110101195512153052') AND (GJXFJYW.PCK.XM = '郭威')) THEN 4 WHEN (GJXFJYW.PCK.SFZH = '110101195512153052') THEN 5 WHEN ((GJXFJYW.PCK.XM = '郭威') AND (CAST((GJXFJYW.PCK.ZZDM) AS TEXT) ~~ '11%') AND (CAST((GJXFJYW.PCK.WTSDDM) AS TEXT) ~~ '11%')) THEN 6 WHEN ((GJXFJYW.PCK.XM = '郭威') AND (CAST((GJXFJYW.PCK.WTSDDM) AS TEXT) ~~ '11%')) THEN 7 WHEN ((GJXFJYW.PCK.XM = '郭威') AND (CAST((GJXFJYW.PCK.ZZDM) AS TEXT) ~~ '11%')) THEN 8 ELSE 9 END, GJXFJYW.PCK.DJSJ
2. 0.000 0.000 ↓ 0.0

Hash Join (cost=1,423,276.09..1,423,458.42 rows=1 width=316) (actual rows= loops=)

  • Hash Cond: (CAST((GJXFJYW.PCK.RECORDID) AS TEXT) = A.PCKID)
3. 0.000 0.000 ↓ 0.0

Bitmap Heap Scan on PCK (cost=59.53..236.29 rows=1,468 width=316) (actual rows= loops=)

  • Recheck Cond: ((((XM = '威') AND (CAST((WTSDDM) AS TEXT) ~~ '11%')) OR ((XM = '威') AND (CAST((ZZDM) AS TEXT) ~~ '11%'))) OR (SFZH = '110101195512153052'))
  • Filter: (((XM = '威') AND ((CAST((WTSDDM) AS TEXT) ~~ '11%') OR (CAST((ZZDM) AS TEXT) ~~ '11%'))) OR (SFZH = '110101195512153052'))
4. 0.000 0.000 ↓ 0.0

BitmapOr (cost=59.53..59.53 rows=1,473 width=0) (actual rows= loops=)

5. 0.000 0.000 ↓ 0.0

BitmapOr (cost=36.47..36.47 rows=56 width=0) (actual rows= loops=)

6. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on PCKINDEX1 (cost=0.00..26.60 rows=24 width=0) (actual rows= loops=)

  • Index Cond: ((XM = '威') AND (CAST((WTSDDM) AS TEXT) OPERATOR(SYS_CATALOG.>=) '11') AND (CAST((WTSDDM) AS TEXT) OPERATOR(SYS_CATALOG.<) '12'))
7. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on PCKINDEX1 (cost=0.00..9.13 rows=32 width=0) (actual rows= loops=)

  • Index Cond: ((XM = '威') AND (CAST((ZZDM) AS TEXT) OPERATOR(SYS_CATALOG.>=) '11') AND (CAST((ZZDM) AS TEXT) OPERATOR(SYS_CATALOG.<) '12'))
8. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on PCKINDEX2 (cost=0.00..22.69 rows=1,417 width=0) (actual rows= loops=)

  • Index Cond: (SFZH = '110101195512153052')
9. 0.000 0.000 ↓ 0.0

Hash (cost=1,423,216.54..1,423,216.54 rows=2 width=32) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Subquery Scan A (cost=1,423,216.49..1,423,216.54 rows=2 width=32) (actual rows= loops=)

11. 0.000 0.000 ↓ 0.0

HashAggregate (cost=1,423,216.49..1,423,216.52 rows=2 width=82) (actual rows= loops=)

12. 0.000 0.000 ↓ 0.0

Bitmap Heap Scan on PCK (cost=1,423,030.11..1,423,205.77 rows=1,429 width=82) (actual rows= loops=)

  • Recheck Cond: ((((XM = '郭威') AND (CAST((WTSDDM) AS TEXT) ~~ '11%') AND (NMBZ = 0)) OR ((XM = '郭威') AND (CAST((ZZDM) AS TEXT) ~~ '11%') AND (NMBZ = 0))) OR ((SFZH = '110101195512153052') AND (NMBZ = 0)))
  • Filter: (((XM = '郭威') AND ((CAST((WTSDDM) AS TEXT) ~~ '11%') OR (CAST((ZZDM) AS TEXT) ~~ '11%'))) OR (SFZH = '110101195512153052'))
13. 0.000 0.000 ↓ 0.0

BitmapOr (cost=1,423,030.11..1,423,030.11 rows=1,434 width=0) (actual rows= loops=)

14. 0.000 0.000 ↓ 0.0

BitmapOr (cost=38.34..38.34 rows=54 width=0) (actual rows= loops=)

15. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on PCKINDEX1 (cost=0.00..28.42 rows=23 width=0) (actual rows= loops=)

  • Index Cond: ((XM = '郭威') AND (CAST((WTSDDM) AS TEXT) OPERATOR(SYS_CATALOG.>=) '11') AND (CAST((WTSDDM) AS TEXT) OPERATOR(SYS_CATALOG.<) '12') AND (NMBZ = 0))
16. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on PCKINDEX1 (cost=0.00..9.21 rows=31 width=0) (actual rows= loops=)

  • Index Cond: ((XM = '郭威') AND (CAST((ZZDM) AS TEXT) OPERATOR(SYS_CATALOG.>=) '11') AND (CAST((ZZDM) AS TEXT) OPERATOR(SYS_CATALOG.<) '12') AND (NMBZ = 0))
17. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on PCKINDEX1 (cost=0.00..1,422,991.41 rows=1,380 width=0) (actual rows= loops=)

  • Index Cond: ((SFZH = '110101195512153052') AND (NMBZ = 0))(29 行)