<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: NiFi UpdateRecord processor is throwing PatternSyntaxException: Unclosed character class near index 4 in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/NiFi-UpdateRecord-processor-is-throwing/m-p/234173#M84977</link>
    <description>&lt;A rel="user" href="https://community.cloudera.com/users/97799/ravikumarkargam.html" nodeid="97799"&gt;@ravi kargam&lt;/A&gt;&lt;P&gt;As a work around Instead of using &lt;STRONG&gt;replaceRegex&lt;/STRONG&gt; function use &lt;STRONG&gt;replace&lt;/STRONG&gt; function with below configs:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;U&gt;UpdateRecord Configs:&lt;/U&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Replacement Value Strategy
&lt;/P&gt;&lt;PRE&gt;Record Path Value&lt;/PRE&gt;&lt;P&gt;&lt;STRONG&gt;/employeeName&lt;/STRONG&gt;&lt;/P&gt;&lt;PRE&gt;replace(/employeeName,'[','(')&lt;/PRE&gt;&lt;P&gt;&lt;STRONG&gt;(or)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;If you are &lt;STRONG&gt;updating only one column value&lt;/STRONG&gt; then &lt;/P&gt;&lt;P&gt;Replacement Value Strategy
&lt;/P&gt;&lt;PRE&gt;Literal Value&lt;/PRE&gt;&lt;P&gt;&lt;STRONG&gt;/employeeName&lt;/STRONG&gt;&lt;/P&gt;&lt;PRE&gt;${field.value:replaceAll('\\[','(')}&lt;/PRE&gt;</description>
    <pubDate>Fri, 16 Nov 2018 06:14:00 GMT</pubDate>
    <dc:creator>Shu_ashu</dc:creator>
    <dc:date>2018-11-16T06:14:00Z</dc:date>
    <item>
      <title>NiFi UpdateRecord processor is throwing PatternSyntaxException: Unclosed character class near index 4</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/NiFi-UpdateRecord-processor-is-throwing/m-p/234172#M84976</link>
      <description>&lt;P&gt;&lt;A href="https://community.cloudera.com/legacyfs/online/attachments/93630-updaterecord-config-exception.jpg"&gt;updaterecord-config-exception.jpg&lt;/A&gt;I am trying to replace square bracket symbol &lt;B&gt;[&lt;/B&gt; with parenthesis symbol &lt;B&gt;(&lt;/B&gt; in my employeeName column in my csvReader structure with below syntax&lt;/P&gt;&lt;P&gt;replaceRegex(/employeeName, "[\\[]", "(")&lt;/P&gt;&lt;P&gt;Processor is throwing following exception. &lt;/P&gt;&lt;P&gt;RecordPathException:
java.util.regex.PatternSyntaxException: Unclosed character class near index 4 [\\[]&lt;/P&gt;&lt;P&gt;same regular expression compiled successfully using java method java.util.regex.Pattern.compile method.&lt;/P&gt;&lt;P&gt;replaceRegex is working fine for other special characters such as {, &amp;lt;, ", _, - etc. &lt;/P&gt;&lt;P&gt;Please see the attachment for more details.&lt;/P&gt;&lt;P&gt;Any help is greatly appreciated.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;RK&lt;/P&gt;</description>
      <pubDate>Fri, 16 Nov 2018 05:46:10 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/NiFi-UpdateRecord-processor-is-throwing/m-p/234172#M84976</guid>
      <dc:creator>ravi0007</dc:creator>
      <dc:date>2018-11-16T05:46:10Z</dc:date>
    </item>
    <item>
      <title>Re: NiFi UpdateRecord processor is throwing PatternSyntaxException: Unclosed character class near index 4</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/NiFi-UpdateRecord-processor-is-throwing/m-p/234173#M84977</link>
      <description>&lt;A rel="user" href="https://community.cloudera.com/users/97799/ravikumarkargam.html" nodeid="97799"&gt;@ravi kargam&lt;/A&gt;&lt;P&gt;As a work around Instead of using &lt;STRONG&gt;replaceRegex&lt;/STRONG&gt; function use &lt;STRONG&gt;replace&lt;/STRONG&gt; function with below configs:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;U&gt;UpdateRecord Configs:&lt;/U&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Replacement Value Strategy
&lt;/P&gt;&lt;PRE&gt;Record Path Value&lt;/PRE&gt;&lt;P&gt;&lt;STRONG&gt;/employeeName&lt;/STRONG&gt;&lt;/P&gt;&lt;PRE&gt;replace(/employeeName,'[','(')&lt;/PRE&gt;&lt;P&gt;&lt;STRONG&gt;(or)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;If you are &lt;STRONG&gt;updating only one column value&lt;/STRONG&gt; then &lt;/P&gt;&lt;P&gt;Replacement Value Strategy
&lt;/P&gt;&lt;PRE&gt;Literal Value&lt;/PRE&gt;&lt;P&gt;&lt;STRONG&gt;/employeeName&lt;/STRONG&gt;&lt;/P&gt;&lt;PRE&gt;${field.value:replaceAll('\\[','(')}&lt;/PRE&gt;</description>
      <pubDate>Fri, 16 Nov 2018 06:14:00 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/NiFi-UpdateRecord-processor-is-throwing/m-p/234173#M84977</guid>
      <dc:creator>Shu_ashu</dc:creator>
      <dc:date>2018-11-16T06:14:00Z</dc:date>
    </item>
    <item>
      <title>Re: NiFi UpdateRecord processor is throwing PatternSyntaxException: Unclosed character class near index 4</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/NiFi-UpdateRecord-processor-is-throwing/m-p/234174#M84978</link>
      <description>&lt;P&gt;Your suggestion worked. Thank you Shu for promptly addressing my issue.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Nov 2018 06:23:55 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/NiFi-UpdateRecord-processor-is-throwing/m-p/234174#M84978</guid>
      <dc:creator>ravi0007</dc:creator>
      <dc:date>2018-11-16T06:23:55Z</dc:date>
    </item>
    <item>
      <title>Re: NiFi UpdateRecord processor is throwing PatternSyntaxException: Unclosed character class near index 4</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/NiFi-UpdateRecord-processor-is-throwing/m-p/234175#M84979</link>
      <description>&lt;P&gt;looke like issue in NiFi. created Jira ticket for it&lt;/P&gt;&lt;P&gt;&lt;A href="https://issues.apache.org/jira/browse/NIFI-5826" target="_blank"&gt;https://issues.apache.org/jira/browse/NIFI-5826&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 16 Nov 2018 07:06:18 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/NiFi-UpdateRecord-processor-is-throwing/m-p/234175#M84979</guid>
      <dc:creator>ravi0007</dc:creator>
      <dc:date>2018-11-16T07:06:18Z</dc:date>
    </item>
  </channel>
</rss>

