(
(declare %kqp%tx_result_binding_0_0 (OptionalType (StructType '('Max0 (DataType 'Date32)) '('Min0 (DataType 'Date32)))))
(let $1 (DataType 'Date32))
(let $2 '('('"_logical_id" '1586) '('"_id" '"62a409ad-ca597d24-87ee8405-1a5b99e") '('"_wide_channels" (StructType '('_yql_agg_0 $1) '('_yql_agg_1 $1)))))
(let $3 (DqPhyStage '() (lambda '() (block '(
  (let $17 (KqpTable '"/local/test_db/olap_yatests/clickbench/hits" '"72075186224037897:8" '"" '1))
  (let $18 (KqpBlockReadOlapTableRanges $17 (Void) '('"EventDate") '() '() (lambda '($19) (block '(
    (let $20 '('_yql_agg_0 'max '"EventDate"))
    (let $21 '('_yql_agg_1 'min '"EventDate"))
    (return (TKqpOlapAgg $19 '($20 $21) '()))
  )))))
  (return (WideFromBlocks (FromFlow $18)))
))) $2))
(let $4 (DqCnUnionAll (TDqOutput $3 '0)))
(let $5 (OptionalType (StructType '('Max0 $1) '('Min0 $1))))
(let $6 (DqPhyStage '($4) (lambda '($22) (block '(
  (let $23 (lambda '($27 $28) $27 $28))
  (let $24 (Bool 'false))
  (let $25 (lambda '($33 $34 $35 $36) (AggrMax $33 $35) (AggrMin $34 $36)))
  (let $26 (WideCondense1 (ToFlow $22) $23 (lambda '($29 $30 $31 $32) $24) $25))
  (return (FromFlow (Condense (NarrowMap (Take $26 (Uint64 '1)) (lambda '($37 $38) (AsStruct '('Max0 $37) '('Min0 $38)))) (Nothing $5) (lambda '($39 $40) $24) (lambda '($41 $42) (Just $41)))))
))) '('('"_logical_id" '2121) '('"_id" '"9751f30e-83a8d148-bc9cb8e2-29b34030"))))
(let $7 (DqCnValue (TDqOutput $6 '0)))
(let $8 '('('"type" '"generic")))
(let $9 (KqpPhysicalTx '($3 $6) '($7) '() $8))
(let $10 '"%kqp%tx_result_binding_0_0")
(let $11 '('('"_logical_id" '2229) '('"_id" '"679b8eae-28443eda-39c12b47-3c043c3") '('"_partition_mode" '"single")))
(let $12 (DqPhyStage '() (lambda '() (block '(
  (let $43 %kqp%tx_result_binding_0_0)
  (return (Iterator (AsList (AsStruct '('"column0" (Member $43 'Min0)) '('"column1" (Member $43 'Max0))))))
))) $11))
(let $13 (DqCnResult (TDqOutput $12 '0) '('"column0" '"column1")))
(let $14 (KqpTxResultBinding $5 '0 '0))
(let $15 (KqpPhysicalTx '($12) '($13) '('($10 $14)) $8))
(let $16 (OptionalType $1))
(return (KqpPhysicalQuery '($9 $15) '((KqpTxResultBinding (ListType (StructType '('"column0" $16) '('"column1" $16))) '1 '0)) '('('"type" '"query"))))
)
