Apache Nifi - 在单个流程中从多个表中读取数据
Apache Nifi - Read data from multiple tables in a single flow
我计划将 Apache Nifi 用于数据摄取用例。源可以是平面文件和 Teradata
数据库,输出接收器可以是 Oracle
数据库。我创建了几个流来使用 GetFile
从平面文件读取数据,使用 ExecuteSQL
从 Teradata 数据库读取数据,并使用 PutSQL
将数据加载到 Oracle 数据库。一切似乎都运行良好。我们预测源系统将来可能会发生变化,我注意到 Nifi 中的处理器可以支持该源。
现在我的问题是,是否可以从 Teradata 数据库中读取多个 table 并将数据加载到单个 Nifi 流中的 oracle 数据库中的多个 table?我为每个 table 构建了单独的流程,它似乎工作正常。
您使用的是什么版本的 Nifi?如果您使用的是 ExecuteSQL for each table, and a recent version of NiFi (1.0.0 and later) you could use the ListDatabaseTables processor, then a ReplaceText to create a SQL statement to get the rows for that table (using NiFi Expression Language),则将其发送到 ExecuteSQL 以进行提取,以及您必须将行放入 Oracle table(s) 的任何下游处理器。
我计划将 Apache Nifi 用于数据摄取用例。源可以是平面文件和 Teradata
数据库,输出接收器可以是 Oracle
数据库。我创建了几个流来使用 GetFile
从平面文件读取数据,使用 ExecuteSQL
从 Teradata 数据库读取数据,并使用 PutSQL
将数据加载到 Oracle 数据库。一切似乎都运行良好。我们预测源系统将来可能会发生变化,我注意到 Nifi 中的处理器可以支持该源。
现在我的问题是,是否可以从 Teradata 数据库中读取多个 table 并将数据加载到单个 Nifi 流中的 oracle 数据库中的多个 table?我为每个 table 构建了单独的流程,它似乎工作正常。
您使用的是什么版本的 Nifi?如果您使用的是 ExecuteSQL for each table, and a recent version of NiFi (1.0.0 and later) you could use the ListDatabaseTables processor, then a ReplaceText to create a SQL statement to get the rows for that table (using NiFi Expression Language),则将其发送到 ExecuteSQL 以进行提取,以及您必须将行放入 Oracle table(s) 的任何下游处理器。