<i id='FLGmZ'><tr id='FLGmZ'><dt id='FLGmZ'><q id='FLGmZ'><span id='FLGmZ'><b id='FLGmZ'><form id='FLGmZ'><ins id='FLGmZ'></ins><ul id='FLGmZ'></ul><sub id='FLGmZ'></sub></form><legend id='FLGmZ'></legend><bdo id='FLGmZ'><pre id='FLGmZ'><center id='FLGmZ'></center></pre></bdo></b><th id='FLGmZ'></th></span></q></dt></tr></i><div id='FLGmZ'><tfoot id='FLGmZ'></tfoot><dl id='FLGmZ'><fieldset id='FLGmZ'></fieldset></dl></div>

  • <tfoot id='FLGmZ'></tfoot>
      <legend id='FLGmZ'><style id='FLGmZ'><dir id='FLGmZ'><q id='FLGmZ'></q></dir></style></legend>

          <bdo id='FLGmZ'></bdo><ul id='FLGmZ'></ul>

        <small id='FLGmZ'></small><noframes id='FLGmZ'>

        Nifi PutSQL 时间戳/日期时间错误无法转换错误

        时间:2023-08-22
      1. <legend id='MkqU4'><style id='MkqU4'><dir id='MkqU4'><q id='MkqU4'></q></dir></style></legend>

            • <bdo id='MkqU4'></bdo><ul id='MkqU4'></ul>
            • <small id='MkqU4'></small><noframes id='MkqU4'>

                <tbody id='MkqU4'></tbody>
              <tfoot id='MkqU4'></tfoot>

              <i id='MkqU4'><tr id='MkqU4'><dt id='MkqU4'><q id='MkqU4'><span id='MkqU4'><b id='MkqU4'><form id='MkqU4'><ins id='MkqU4'></ins><ul id='MkqU4'></ul><sub id='MkqU4'></sub></form><legend id='MkqU4'></legend><bdo id='MkqU4'><pre id='MkqU4'><center id='MkqU4'></center></pre></bdo></b><th id='MkqU4'></th></span></q></dt></tr></i><div id='MkqU4'><tfoot id='MkqU4'></tfoot><dl id='MkqU4'><fieldset id='MkqU4'></fieldset></dl></div>

                • 本文介绍了Nifi PutSQL 时间戳/日期时间错误无法转换错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我尝试了建议使用UpdateAttribute"处理器来消除时间戳格式转换错误的解决方案,即ConvertJSONtoSQL-> UpdateAttribute--> PutSQL

                  I tried the solution suggested to remove the timestamp format conversion error by using "UpdateAttribute" processor i.e. ConvertJSONtoSQL-> UpdateAttribute--> PutSQL

                  在 UpdateAttribute 中我使用了

                  In UpdateAttribute I used

                  Property               Value
                  ---------------        ------------------------
                  sql.args.4.value ->    ${sql.args.4.original:format("yyyy-MM-dd HH:mm:ss")}
                  

                  日志:

                  sql.args.4.value的值为'',无法转换为时间戳在org.apache.nifi.processors.standard.PutSQL.setParameters(PutSQL.java:690)在

                  The value of the sql.args.4.value is '', which cannot be converted to a timestamp at org.apache.nifi.processors.standard.PutSQL.setParameters(PutSQL.java:690) at

                  在不使用 UpdateAttribute 的情况下,我还尝试了直接 ConvertJSONtoSQL-> PutSQL .日志在引用 'Aug 14 2017 10:17:00 EDT' 中显示了与 datetime 值相同的错误,即当我们使用 UpdateAttribute 时,它​​只是删除该值并放置空引号,但错误未解决.

                  Without the use of UpdateAttribute I also tried direct ConvertJSONtoSQL-> PutSQL . Log showed the same error with datetime value in quote 'Aug 14 2017 10:17:00 EDT' i.e. when we use UpdateAttribute, it just removes the value and put empty quotes but the error is not resolved.

                  注意: MySQL 表具有这些列的日期时间数据类型,不确定为什么尝试转换为时间戳会出错.我还在本地主机上的源表和目标表中尝试了 Timestamp 数据类型,但不走运!

                  Note: MySQL table has datetime datatype for those columns not sure why it errors out by trying to convert to TimeStamp. I also tried Timestamp datatype in source and target table on localhost, no luck!

                  推荐答案

                  我找到了问题的答案

                  sql.args.n.value ->${sql.args.n.value:format("yyyy-MM-dd HH:mm:ss.SSS")}.

                  这篇关于Nifi PutSQL 时间戳/日期时间错误无法转换错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:将 SQL 连接到 apache nifi 下一篇:如何在 NiFi 中映射流文件中的列数据?

                  相关文章

                  最新文章

                • <i id='8RO2g'><tr id='8RO2g'><dt id='8RO2g'><q id='8RO2g'><span id='8RO2g'><b id='8RO2g'><form id='8RO2g'><ins id='8RO2g'></ins><ul id='8RO2g'></ul><sub id='8RO2g'></sub></form><legend id='8RO2g'></legend><bdo id='8RO2g'><pre id='8RO2g'><center id='8RO2g'></center></pre></bdo></b><th id='8RO2g'></th></span></q></dt></tr></i><div id='8RO2g'><tfoot id='8RO2g'></tfoot><dl id='8RO2g'><fieldset id='8RO2g'></fieldset></dl></div>

                  <small id='8RO2g'></small><noframes id='8RO2g'>

                  <legend id='8RO2g'><style id='8RO2g'><dir id='8RO2g'><q id='8RO2g'></q></dir></style></legend>
                • <tfoot id='8RO2g'></tfoot>

                        <bdo id='8RO2g'></bdo><ul id='8RO2g'></ul>