<?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: Problem with transform date to long in nifi in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Problem-with-transform-date-to-long-in-nifi/m-p/380962#M244196</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/80381"&gt;@SAMSAL&lt;/a&gt;&amp;nbsp;, Yes i can convert negative value back but i need to send this date as long to other system and this is my problem with converting this date to long in nifi using toNumber() because my value is negative&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 18 Dec 2023 13:49:57 GMT</pubDate>
    <dc:creator>MWM</dc:creator>
    <dc:date>2023-12-18T13:49:57Z</dc:date>
    <item>
      <title>Problem with transform date to long in nifi</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Problem-with-transform-date-to-long-in-nifi/m-p/380934#M244193</link>
      <description>&lt;P&gt;Hi guys,&lt;/P&gt;&lt;P&gt;I have some problems with transform date from string to long in NIFI. I have date like this: "02-01-1968|" and I need to transform this to long. i am using UpdateAttribte Processor to format it to number like this:&amp;nbsp;${my_date:toDate("dd-MM-yyyy","GMT"):toNumber()})} but I have result like this: "my_date" : -63072000000 .Does anyone know how to solve this better?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Dec 2023 10:57:46 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Problem-with-transform-date-to-long-in-nifi/m-p/380934#M244193</guid>
      <dc:creator>MWM</dc:creator>
      <dc:date>2023-12-18T10:57:46Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with transform date to long in nifi</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Problem-with-transform-date-to-long-in-nifi/m-p/380961#M244195</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/105912"&gt;@MWM&lt;/a&gt; ,&lt;/P&gt;&lt;P&gt;The reason you are getting negative value is because the minimum date in epoch is "January 1st, 1970"&amp;nbsp; which corresponds to "0".&amp;nbsp; It turns out you can still convert the negative value back to date using the following expression:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;${my_date:toDate():format("dd-MM-yyyy")}&lt;/LI-CODE&gt;&lt;P&gt;If that helps please accept solution.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Dec 2023 13:45:52 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Problem-with-transform-date-to-long-in-nifi/m-p/380961#M244195</guid>
      <dc:creator>SAMSAL</dc:creator>
      <dc:date>2023-12-18T13:45:52Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with transform date to long in nifi</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Problem-with-transform-date-to-long-in-nifi/m-p/380962#M244196</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/80381"&gt;@SAMSAL&lt;/a&gt;&amp;nbsp;, Yes i can convert negative value back but i need to send this date as long to other system and this is my problem with converting this date to long in nifi using toNumber() because my value is negative&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Dec 2023 13:49:57 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Problem-with-transform-date-to-long-in-nifi/m-p/380962#M244196</guid>
      <dc:creator>MWM</dc:creator>
      <dc:date>2023-12-18T13:49:57Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with transform date to long in nifi</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Problem-with-transform-date-to-long-in-nifi/m-p/380963#M244197</link>
      <description>&lt;P&gt;Is the problem that the other system doesnt take negative values?&lt;/P&gt;</description>
      <pubDate>Mon, 18 Dec 2023 14:06:15 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Problem-with-transform-date-to-long-in-nifi/m-p/380963#M244197</guid>
      <dc:creator>SAMSAL</dc:creator>
      <dc:date>2023-12-18T14:06:15Z</dc:date>
    </item>
  </channel>
</rss>

