IBM Support

Flat File adapter does not accurately sort by timestamp with timestamps are within the one second of one another

Troubleshooting


Problem

Flat File adapter does not accurately sort by timestamp with timestamps are within the one second of one another.

Symptom

When sorting input files by timestamp in a Linux or UNIX system, if the file modification dates are within the same second those files will be sorted by file name rather than by timestamp.

Cause

This is caused by a Java™ limitation in UNIX platforms where Java fails to return the millisecond value of the timestamp, but only the number of seconds. This is an existing issue in Java addressed by the following unfixed report.
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6939260

Environment


Resolving The Problem

The adapter is not able to sort files created in the same second by modified timestamp. As a result, the only workaround is to place the timestamp in the file name and then sort by file name instead. This will allow the user to preserve the needed functionality while working around this Java limitation.

[{"Product":{"code":"SSMKUK","label":"WebSphere Adapters Family"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Adapter for FlatFiles","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF012","label":"IBM i"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"},{"code":"PF035","label":"z\/OS"}],"Version":"7.0;6.2;6.1;6.0.2;6.0","Edition":"","Line of Business":{"code":"","label":""}}]

Document Information

Modified date:
15 June 2018

UID

swg21446607