(
(declare %kqp%tx_result_binding_0_0 (OptionalType (StructType '('Count0 (DataType 'Uint64)) '('Count1 (DataType 'Uint64)))))
(let $1 (Uint64 '1))
(let $2 (Bool 'false))
(let $3 (DataType 'Uint64))
(let $4 '('('"_logical_id" '972) '('"_id" '"b80106bf-cfc02a8a-a933b806-d52399e4") '('"_wide_channels" (StructType '('_yql_agg_0 $3) '('_yql_agg_1 $3)))))
(let $5 (DqPhyStage '() (lambda '() (block '(
  (let $17 '@@["StructType";[["key";["OptionalType";["DataType";"Uint64"]]];["subkey";["DataType";"Uint64"]]]]@@)
  (let $18 (YqlRowSpec '('NativeYtTypeFlags '0) '('StrictSchema '1) '('UniqueKeys '0) '('Type $17)))
  (let $19 (YtMeta '('CanWrite '1) '('DoesExist '1) '('YqlCompatibleScheme '1) '('InferredScheme '0) '('IsDynamic '0) '('Attrs '('('"native_strict_schema" 'false)))))
  (let $20 (YtStat '('Id '"Input") '('RecordsCount '"5") '('DataSize '"126") '('ChunkCount '1) '('ModifyTime '0) '('Revision '0)))
  (let $21 (YtTable '"Input" $18 $19 $20 '() (Void) (Void) '"/Root/plato"))
  (let $22 (YtReadTable! world (DataSource '"yt" '"/Root/plato") '((YtSection '((YtPath $21 '('"key" '"subkey") (Void) (Void))) '()))))
  (let $23 (lambda '($29) $1 (AggrCountInit $29)))
  (let $24 (lambda '($33 $34 $35) (AggrAdd $34 $1) (AggrCountUpdate $33 $35)))
  (return (FromFlow (WideCondense1 (WideMap (WideFilter (DqReadWideWrap $22 '()) (lambda '($25 $26) (!= $26 (Int32 '"5")))) (lambda '($27 $28) $27)) $23 (lambda '($30 $31 $32) $2) $24)))
))) $4))
(let $6 (DqCnUnionAll (TDqOutput $5 '0)))
(let $7 (OptionalType (StructType '('Count0 $3) '('Count1 $3))))
(let $8 (DqPhyStage '($6) (lambda '($36) (block '(
  (let $37 (lambda '($40 $41) $40 $41))
  (let $38 (lambda '($46 $47 $48 $49) (AggrAdd $46 $48) (AggrAdd $47 $49)))
  (let $39 (WideCondense1 (ToFlow $36) $37 (lambda '($42 $43 $44 $45) $2) $38))
  (return (FromFlow (Condense (NarrowMap (Take $39 $1) (lambda '($50 $51) (AsStruct '('Count0 $50) '('Count1 $51)))) (Nothing $7) (lambda '($52 $53) $2) (lambda '($54 $55) (Just $54)))))
))) '('('"_logical_id" '1903) '('"_id" '"b5be200c-876d647b-b7c38cb3-844683bf"))))
(let $9 (DqCnValue (TDqOutput $8 '0)))
(let $10 (KqpPhysicalTx '($5 $8) '($9) '() '('('"type" '"compute"))))
(let $11 '"%kqp%tx_result_binding_0_0")
(let $12 '('('"_logical_id" '2035) '('"_id" '"166b8e9b-9f8467ae-479b80a7-66dc027d") '('"_partition_mode" '"single")))
(let $13 (DqPhyStage '() (lambda '() (block '(
  (let $56 %kqp%tx_result_binding_0_0)
  (let $57 (Uint64 '0))
  (return (Iterator (AsList (AsStruct '('"column0" (Coalesce (Member $56 'Count0) $57)) '('"column1" (Coalesce (Member $56 'Count1) $57))))))
))) $12))
(let $14 (DqCnResult (TDqOutput $13 '0) '('"column0" '"column1")))
(let $15 (KqpTxResultBinding $7 '0 '0))
(let $16 (KqpPhysicalTx '($13) '($14) '('($11 $15)) '('('"type" '"generic"))))
(return (KqpPhysicalQuery '($10 $16) '((KqpTxResultBinding (ListType (StructType '('"column0" $3) '('"column1" $3))) '1 '0)) '('('"type" '"query"))))
)
