Problem appending to a file

Homepage Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Problem appending to a file

  • Creator
    Topic
  • #52127
    George Kulz
    Participant

    Hi all.

    I have configured a thread to use a FILE protocol so that it will append a billing flat record to a file. Our new pharmacy system does a midnight run every night and generates a billing flat record, which is then supposed to be appended to the filename I specified. However, I notice when I get in in the morning, the file is empty. Now, there are other processes that go on behind the scenes at our site. The billing file is supposed to be processed sometime early morning, and then around 11:00 PM the billing file is archived, and a new 0-length file is created in its place to prepare for the next midnight run. It looks as though all the permissions on the file are OK to me, so I don’t think that’s the problem. Also, when I shut down the thread, turn it back on, then resend the last billing flat record, it appends to the file just fine. Do I maybe have something else set wrong? Would it be better if I didn’t append to the file at all but just overwrote the last one instead, since it has already been archived anyway?

    Thanks in advance.

    -George

Viewing 1 reply thread
  • Author
    Replies
    • #73179
      Robert Kersemakers
      Participant

      Hi George,

      Hmmm… I think I have seen the same behaviour a few times, but I’m not sure under which conditions. I think it was when I wrote lines to a file with the FILE protocol: somehow CL always wants to write to the same file. If this file is processed/removed by another system/process, then CL loses the link to the file and can’t write to it any more. But my memory is legendary terrible, so…

      My suggestion: try the FILESET-LOCAL protocol. It also allows you to write to one file and you can append lines to the file as well. I am using FILESET-LOCAL a lot and haven’t encountered problems with it.

      Hope this helps.

      Zuyderland Medisch Centrum; Heerlen/Sittard; The Netherlands

    • #73180
      George Kulz
      Participant

      Thanks Robert, this worked beautifully.

      -George

Viewing 1 reply thread
  • The forum ‘Cloverleaf’ is closed to new topics and replies.

Forum Statistics

Registered Users
5,105
Forums
28
Topics
9,278
Replies
34,382
Topic Tags
281