1. 自定义udf
1)pom.xml
<dependency> <groupId>com.aliyun.odps</groupId> <artifactId>odps-sdk-udf</artifactId> <version>0.17.3</version> </dependency> </dependencies>
2) 函数套路:
package com.odps.udf; import com.aliyun.odps.udf.UDF; public final class Upper_test extends UDF{ public String evaluate(String s){ ## if(s==null) {return null;} ## return s.toUpperCase(); ## 替换该函数内容 } }
2. ODPS的查询结果无法复制,只能扣你需要的值
F12 或者页面右键(检查)调出页面源码;
左上角有 箭头,点击
、
然后移到,要扣的值那里点击。右边对应源码中的值即被选中。