本文介绍了如何实施复杂的编校?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hadoop只能通过修改HDFS配置来支持简单的编辑,例如:有一个卡号A:1234-5678-8765-4321,它可以是由正则表达式识别,然后替换为预定义的表达式,如:XXXX-XXXX-XXXX-XXXX,如下所示:




Hadoop can only support simple redaction via modifying HDFS configuration, for example: there is a card number A: "1234-5678-8765-4321", it can be recognized by regex and then replaced by a predefined expression like: "XXXX-XXXX-XXXX-XXXX", as shown below:

My question is can it transfer number A to: "1234-5678-XXXX-4321" rather than the predefined expression?

解决方案

You can use ( ) to grab patterns and $1 $2 ... $n to reuse them into the replace expression

这篇关于如何实施复杂的编校?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-21 16:09