blob: 3518cac97ed8f8e2128e65515a6692273b158c81 (
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
24
25
|
/* postgres can not */
/* syntax version 1 */
USE plato;
$udfScript = @@
def f(key, input):
for i in input:
yield {
'key': i.key,
'value': i.value,
'pass': 10
}
@@;
$udf_stream = Python3::f(
Callable<
(String,Stream<Struct<key:String,value:String>>)
->
Stream<Struct<key:String,value:String,pass:Int32>>
>, $udfScript);
REDUCE Input
ON key
USING $udf_stream(TableRow());
|