From f71fee5df6662b9f11c8b02230278e846242678f Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Tue, 16 Apr 2019 09:18:37 -0500 Subject: [PATCH] add last change --- route_sql/build/rep_totals.sql | 1 + 1 file changed, 1 insertion(+) diff --git a/route_sql/build/rep_totals.sql b/route_sql/build/rep_totals.sql index f0846db..dde3617 100644 --- a/route_sql/build/rep_totals.sql +++ b/route_sql/build/rep_totals.sql @@ -33,6 +33,7 @@ SELECT ,to_char(sum(sales_adj),'999,999,999') sales_adj ,to_char(sum(sales_adj - scogs_adj),'999,999,999') margin_adj ,count(iterdef) "# of changes" + ,(max(iterdef->>'stamp'))::timestamptz "last edit" FROM preagg GROUP BY