Member since
10-07-2025
2
Posts
0
Kudos Received
1
Solution
My Accepted Solutions
| Title | Views | Posted |
|---|---|---|
| 689 | 10-07-2025 10:11 AM |
12-10-2025
08:32 AM
NiFi Version: 2.5.0 When transporting information from one site to another, I need to prepend a 0 to someones PIN as that site has different requirements. I query the data using a QueryRecord processor, like so: SELECT
MsgSeqNbr, PostTime, SSN, EmployeeID,
LName, FName, MName,
CAST(TRIM(LCN) AS BIGINT) AS LCN,
LPAD(PIN, 5, '0'),
EmployeeType, ValidityCode, AgencyOwner, AgencyLocated,
BadgeCreatedBy, BadgeCreatedTime,
BadgeModifiedBy, BadgeModifiedTime,
Clearance, Error, Status
FROM FLOWFILE However I get the following error from Calcite: QUERY...
- Caused by:
org.apache.calcite.runtime.CalciteContentException: From line 5, column 5, column X: No match found for function signature LPAD(<CHARACTER>, <NUMERIC>, <CHARACTER>). I've tried a couple different methods to get this to pass, explicitly defining the type as VARCHAR(5) for both the string and the pattern, using a static value to see if it will pass but the same result occurs. The incoming Avro data has the PIN like so: ...
"PIN" : "111",
... So I know the data type it's receiving truly is a string. Following the ticket that was created for the original implementation it seems the dev's had the same intent for how to use the function: https://issues.apache.org/jira/browse/CALCITE-5451 Anyone else encounter a similar issue with Calcite?
... View more
Labels:
- Labels:
-
Apache NiFi
10-07-2025
10:11 AM
Wanted to reply because I was also having this issue on Windows Server. @templarian has the working solution. Whenever you first start NiFi leave the logback configurations unchanged, however we set ours to debug to have more insight into the issue. <configuration scan="true" scanPeriod="30 seconds" debug="true">
...
</configuration> NiFi's PID is blocking the file constantly, never releasing it, this causes the RollingFileAppender to never be able to change the filename: 16:32:07,611 |-INFO in c.q.l.core.rolling.helper.TimeBasedArchiveRemover - No removal attempts were made on account of totalSizeCap=3221225472
16:32:07,613 |-INFO in c.q.l.core.rolling.helper.TimeBasedArchiveRemover - No removal attempts were made on account of totalSizeCap=3221225472
16:32:22,499 |-INFO in c.q.l.co.rolling.helper.RenameUtil - Renaming file [C:\nifi-2.5.0\logs\nifi-app.log] to [C:\nifi-2.5.0\logs\nifi-app_2025-10-07_16.0.log5423244956573500.tmp]
16:32:22,499 |-WARN in c.q.l.co.rolling.helper.RenameUtil - Failed to rename file [C:\nifi-2.5.0\logs\nifi-app.log] as [C:\nifi-2.5.0\logs\nifi-app_2025-10-07_16.0.log5423244956573500.tmp].
16:32:22,501 |-WARN in c.q.l.co.rolling.helper.RenameUtil - Please consider leaving the [file] option of RollingFileAppender empty.
16:32:22,502 |-WARN in c.q.l.co.rolling.helper.RenameUtil - See also https://logback.qos.ch/codes.html#renamingError Our workaround was to leave it unchanged on the first launch of NiFi and then remove all the <file/> properties for each appender once each file was initially created. Logback automatically applies these settings so there should be no disruption to NiFi. The appender configuration is identical to @templarian's suggestion. This got rotation and compression working for each of our appenders.
... View more