diff --git a/rebuild_pg.cmd b/deploy/rebuild_pg.cmd similarity index 100% rename from rebuild_pg.cmd rename to deploy/rebuild_pg.cmd diff --git a/ubm_backup.cmd b/deploy/ubm_backup.cmd similarity index 100% rename from ubm_backup.cmd rename to deploy/ubm_backup.cmd diff --git a/ubm_schema.sql b/deploy/ubm_schema.sql similarity index 100% rename from ubm_schema.sql rename to deploy/ubm_schema.sql diff --git a/do_map.pgsql b/functions/do_map.pgsql similarity index 100% rename from do_map.pgsql rename to functions/do_map.pgsql diff --git a/do_map_g_option.pgsql b/functions/do_map_g_option.pgsql similarity index 100% rename from do_map_g_option.pgsql rename to functions/do_map_g_option.pgsql diff --git a/srce.pgsql b/functions/srce.pgsql similarity index 100% rename from srce.pgsql rename to functions/srce.pgsql diff --git a/log.md b/log.md deleted file mode 100644 index 8c51add..0000000 --- a/log.md +++ /dev/null @@ -1,16 +0,0 @@ -## Log of event - -use spreadsheet to build json transactions and dump to a log that links to bank data - -bank -binoculars -**manicure/pedicure** -**necklace** -bassinet & baby stuff -kids phone -dress -hanging chair -**sunglasses** -**footy pajamas** -printing calculator -cash register diff --git a/col_balance.pgsql b/reports/col_balance.pgsql similarity index 100% rename from col_balance.pgsql rename to reports/col_balance.pgsql diff --git a/dcard_bal.pgsql b/reports/dcard_bal.pgsql similarity index 100% rename from dcard_bal.pgsql rename to reports/dcard_bal.pgsql diff --git a/list_maps.pgsql b/reports/list_maps.pgsql similarity index 100% rename from list_maps.pgsql rename to reports/list_maps.pgsql diff --git a/loan_bal.pgsql b/reports/loan_bal.pgsql similarity index 100% rename from loan_bal.pgsql rename to reports/loan_bal.pgsql diff --git a/map_rv_items_not_mapped.pgsql b/reports/map_rv_items_not_mapped.pgsql similarity index 100% rename from map_rv_items_not_mapped.pgsql rename to reports/map_rv_items_not_mapped.pgsql diff --git a/srce_unq.pgsql b/reports/srce_unq.pgsql similarity index 100% rename from srce_unq.pgsql rename to reports/srce_unq.pgsql diff --git a/transaction_range.pgsql b/reports/transaction_range.pgsql similarity index 100% rename from transaction_range.pgsql rename to reports/transaction_range.pgsql diff --git a/srce_defn.pgsql b/srce_defn.pgsql deleted file mode 100644 index 65361c3..0000000 --- a/srce_defn.pgsql +++ /dev/null @@ -1,24 +0,0 @@ -\timing -/* -WITH -ext AS ( -SELECT - srce - ,defn->'unique_constraint'->>'fields' - ,ARRAY(SELECT ae.e::text[] FROM jsonb_array_elements_text(defn->'unique_constraint'->'fields') ae(e)) text_array -FROM - tps.srce - --add where clause for targeted source -) -*/ - -SELECT COUNT(*) FROM -( -SELECT DISTINCT - t.srce - ,(SELECT JSONB_OBJECT_agg(ae.e,rec #> ae.e::text[]) FROM jsonb_array_elements_text(defn->'unique_constraint'->'fields') ae(e)) ja -FROM - tps.trans t - INNER JOIN tps.srce s ON - s.srce = t.srce -) X \ No newline at end of file diff --git a/map_rm.pgsql b/templates/map_rm.pgsql similarity index 100% rename from map_rm.pgsql rename to templates/map_rm.pgsql diff --git a/map_rm_template.pgsql b/templates/map_rm_template.pgsql similarity index 100% rename from map_rm_template.pgsql rename to templates/map_rm_template.pgsql diff --git a/srce_template.pgsql b/templates/srce_template.pgsql similarity index 100% rename from srce_template.pgsql rename to templates/srce_template.pgsql