Steve Vincent wrote:Something that i'd like to do is append data to an existing ascii file from a TI, but current options do not allow this. Even writing to the same file from the same TI from different tabs will overwrite the existing file.
My solution would be to add another command called ASCIIAPPEND, to have the same criteria as ASCIIOUTPUT but adds to the bottom of the file rather than overwriting it. If the file doesn't exist, it should create it.
If others believe that to be a worthwhile addition i'm quite happy to raise a request to Cognos. I can't see it being too difficult, so it'll probably take as long as undo spread has...

Steve, I came across a situation where this would have been handy a day or two back. Have you raised it?
The only down side is what would happen if another process has a write lock on the file. My bet is that this is why we have the current situation where each tab creates its own file; the advantage is that since the tab creates the file itself, there's no possibility that the file could be locked.
My feeling is that the workaround for this chould be an argument in the AsciiAppend function which lets us tell the server what to do if it encounters such a write lock on the file that it's trying to append to:
0 = Ignore and continue processing (default)
1 = Fail the process with an error
2 = Create a new file with a timestamped name and write to that instead of the intended file.
Of course this would require a break away from the Applix mindset of "an error crashes the process even if we don't need or want it to". (See also, creating 256+ character strings in 9.0 which crash the process as opposed to just being ignored as they were in 8.2.12.)
The process should, of course, open the file with its own write lock.