    "create index catalogs_job_id_idx on catalogs(job_id) where job_id is not null"))
 
 (defn rededuplicate-facts []
+  (log/info (trs "[1/6] Creating new fact storage tables..."))
   (jdbc/do-commands
    "CREATE SEQUENCE fact_values_id_seq;"
 

          [(sutils/array-to-param "bigint" Long ids)
           (sutils/array-to-param "bytea" PGobject hashes)])))))

  (jdbc/do-commands
   "DROP TABLE facts"
   "ALTER TABLE facts_transform rename to facts"

        WHERE f.value IS NULL AND fv.value IS NULL")

  ;; populate fact_values.value_hash
  (log/info (trs "[4/6] Computing fact value hashes..."))
  (jdbc/call-with-query-rows
   ["select id, value::text from fact_values"]
   (fn [rows]
