Github user mattyb149 commented on a diff in the pull request:

    https://github.com/apache/nifi/pull/178#discussion_r50171832
  
    --- Diff: 
nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/ExecuteSQL.java
 ---
    @@ -164,17 +166,19 @@ public void process(final OutputStream out) throws 
IOException {
                 });
     
                 // set attribute how many rows were selected
    -            outgoing = session.putAttribute(outgoing, RESULT_ROW_COUNT, 
nrOfRows.get().toString());
    +            fileToProcess = session.putAttribute(fileToProcess, 
RESULT_ROW_COUNT, nrOfRows.get().toString());
     
    -            logger.info("{} contains {} Avro records; transferring to 
'success'", new Object[] {outgoing, nrOfRows.get()});
    -            session.getProvenanceReporter().modifyContent(outgoing, 
"Retrieved " + nrOfRows.get() + " rows", 
stopWatch.getElapsed(TimeUnit.MILLISECONDS));
    -            session.transfer(outgoing, REL_SUCCESS);
    +            logger.info("{} contains {} Avro records; transferring to 
'success'",
    +                    new Object[] {fileToProcess, nrOfRows.get()});
    +            session.getProvenanceReporter().modifyContent(fileToProcess, 
"Retrieved " + nrOfRows.get() + " rows",
    +                    stopWatch.getElapsed(TimeUnit.MILLISECONDS));
    +            session.transfer(fileToProcess, REL_SUCCESS);
             } catch (final ProcessException | SQLException e) {
    --- End diff --
    
    On second thought, a couple of those createConnection() / createStatement() 
things might throw exceptions, so I will keep it in and add the yield :)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to