blob: 33a0b8f8f7b2791037c3a8866c05d3564484671f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
/* syntax version 1 */
/* kikimr can not */
USE plato;
$udfScript = @@
def f(input,x):
for i in input:
yield {
'key': i.key,
'subkey': i.subkey,
'value': i.value,
'pass': x
}
@@;
$udf_stream = Python3::f(
Callable<
(Stream<Struct<key:String,subkey:String,value:String>>,Int32)
->
Stream<Struct<key:String,subkey:String,value:String,pass:Int32>>
>, $udfScript);
PROCESS Input0 using $udf_stream(TableRows(), 2);
|