Skip to content

Commit

Permalink
using circe syntax in flow classes
Browse files Browse the repository at this point in the history
  • Loading branch information
TebaleloS committed Jun 18, 2024
1 parent 1dee384 commit 852d4fd
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ package za.co.absa.atum.server.api.database.flows.functions
import doobie.Fragment
import doobie.implicits.toSqlInterpolator
import doobie.util.Read
import play.api.libs.json.Json
import za.co.absa.atum.model.dto.CheckpointQueryDTO
import za.co.absa.atum.server.api.database.PostgresDatabaseProvider
import za.co.absa.atum.server.api.database.flows.Flows
Expand Down Expand Up @@ -51,7 +50,7 @@ class GetFlowCheckpoints(implicit schema: DBSchema, dbEngine: DoobieEngine[Task]

override def sql(values: CheckpointQueryDTO)(implicit read: Read[CheckpointFromDB]): Fragment = {
val partitioning = PartitioningForDB.fromSeqPartitionDTO(values.partitioning)
val partitioningNormalized = Json.toJson(partitioning).toString
val partitioningNormalized = partitioning.asJson.noSpaces

sql"""SELECT ${Fragment.const(selectEntry)}
FROM ${Fragment.const(functionName)}(
Expand Down

0 comments on commit 852d4fd

Please sign in to comment.