Skip to content

Instantly share code, notes, and snippets.

@jonbartlett
Created August 26, 2016 00:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jonbartlett/2b5de5bc06e262ed387c9bf5616d2b34 to your computer and use it in GitHub Desktop.
Save jonbartlett/2b5de5bc06e262ed387c9bf5616d2b34 to your computer and use it in GitHub Desktop.
Monitor Progress (count of records) on a DB2 ETL Process
#! /bin/sh
for i in {1..1000}
do
db2 -tf write_count.sql
sleep 30s
done
SELECT c.count_rows committed, uc.count_rows not_committed
FROM
( SELECT count(*) count_rows
FROM temp.act_dist_size_ap_session
) c
,
( SELECT count(*) count_rows
FROM temp.act_dist_size_ap_session WITH UR
) uc;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment