                                                                               (conj (vec (:transformations dataset-version))
                                                                                     (assoc transformation
                                                                                            "created" (Instant/ofEpochMilli (System/currentTimeMillis))
-                                                                                           "changedColumns" (diff-columns previous-columns
+                                                                                           "changedColumns" (diff-columns (:columns data-group)
                                                                                                                           columns))))})
     (when (seq data-groups-to-be-created)
       (doseq [dg (adapt data-groups-to-be-created data-groups)]

  "
  [{:keys [tenant-conn claims] :as deps}
   {:keys [job-execution-id transformation data-groups]}
   {:keys [previous-columns columns data-groups-to-be-created data-group dataset-version]}]
  (let [new-dataset-version-id (str (util/squuid))]
    (db.dataset-version/new-dataset-version-2 tenant-conn {:id               new-dataset-version-id
                                                           :dataset-id       (:dataset-id transformation)

        tx-data {:data-groups data-groups
                 :job-execution-id job-execution-id
                 :transformation transformation}
        {:keys [columns data-groups-to-be-created data-group]}
        (try-apply-operation-2 deps tx-data)]
    (post-try-apply-operation-2 deps tx-data
                                {:columns columns
                                 :dataset-version dataset-version
                                 :data-group data-group
                                 :data-groups-to-be-created data-groups-to-be-created})))

