Legacy Hardware and Apps
Can logged data be deleted using FTP?

Hi all,

I can retrieve the DATA_A.DXD file via ftp however my application requires that this file only contains one line of data (the file will be retrieved every logging cycle, 1/min).

To do this I would like to delete this file after I have retrieved it via ftp. I have tried the ftp delete command however I get an IO error. Is there a way to forcibly delete the file via ftp?

Alternatively, can the program be modified to replace the file each cycle rather than append data to it? Even a recursive DELDATA command would be ok. I don't want to have to send the DELDATA command every minute from DeLogger.

Thanks for your help
Denis

Hi all, I can retrieve the DATA_A.DXD file via ftp however my application requires that this file only contains one line of data (the file will be retrieved every logging cycle, 1/min). To do this I would like to delete this file after I have retrieved it via ftp. I have tried the ftp delete command however I get an IO error. Is there a way to forcibly delete the file via ftp? Alternatively, can the program be modified to replace the file each cycle rather than append data to it? Even a recursive DELDATA command would be ok. I don't want to have to send the DELDATA command every minute from DeLogger. Thanks for your help Denis

Good afternoon Denis,

Pity your not using a DT80, all you would need to do is set the file size to 1 record..

I'm not sure what will happen if you delete a file that the logger is using. there is a Delete command available in the FTP (FTP in and type ?) you will need to specify the full path name.

Why are you using FTP for a single line of data, Why not put your channels in the X schedule and poll the DT800 for data by sending a capital X??

Cheers,
Roger

Good afternoon Denis, Pity your not using a DT80, all you would need to do is set the file size to 1 record.. I'm not sure what will happen if you delete a file that the logger is using. there is a Delete command available in the FTP (FTP in and type ?) you will need to specify the full path name. Why are you using FTP for a single line of data, Why not put your channels in the X schedule and poll the DT800 for data by sending a capital X?? Cheers, Roger

Hello again Denis,

Why not have the logger do the delete.

This works

BEGIN
 RA10S
  DO{[DELDATA*]}
 RB10S LOGONB
  REFT
END

Cheers,
Roger

Hello again Denis, Why not have the logger do the delete. This works ```` BEGIN RA10S DO{[DELDATA*]} RB10S LOGONB REFT END ```` Cheers, Roger

Hi Roger,

I am not sure where to put the code you suggested i.e:

BEGIN
 RA10S
  DO{[DELDATA*]}
 RB10S LOGONB
  REFT
END

Could you please help with where to put it in my current program?

DT=\d
BEGIN"C3FRONT"
CATTN
P31=3
RS1S
 RA1M LOGONA GA
  1TK("TK1")
  1*TK("TK2")
  2TK("TK3")
  2*TK("TK4")
  3TK("TK5")
  3*TK("TK6")
  4TK("TK7")
  4*TK("TK8")
  5TK("TK9")
END

Thanks

Hi Roger, I am not sure where to put the code you suggested i.e: ```` BEGIN RA10S DO{[DELDATA*]} RB10S LOGONB REFT END ```` Could you please help with where to put it in my current program? ```` DT=\d BEGIN"C3FRONT" CATTN P31=3 RS1S RA1M LOGONA GA 1TK("TK1") 1*TK("TK2") 2TK("TK3") 2*TK("TK4") 3TK("TK5") 3*TK("TK6") 4TK("TK7") 4*TK("TK8") 5TK("TK9") END ```` Thanks

Good morning Denis,

Try this:

BEGIN"C3FRONT"
P31=3 'Set ISO time date format
'Note; 
'Schedule A will always run before Schedule B
'So we are deleting the data just before the new data is saved.
 RA1M 'Report schedule A every one minute
  DO{[DELDATA*]} 'Delete all data for current job
  'The data deleted is 1 minute old.
 RB1M LOGONB 'Report schedule B every 1 minute.
  1TK("TK1")
  1*TK("TK2")
  2TK("TK3")
  2*TK("TK4")
  3TK("TK5")
  3*TK("TK6")
  4TK("TK7")
  4*TK("TK8")
  5TK("TK9")
END

Cheers,
Roger

Good morning Denis, Try this: ```` BEGIN"C3FRONT" P31=3 'Set ISO time date format 'Note; 'Schedule A will always run before Schedule B 'So we are deleting the data just before the new data is saved. RA1M 'Report schedule A every one minute DO{[DELDATA*]} 'Delete all data for current job 'The data deleted is 1 minute old. RB1M LOGONB 'Report schedule B every 1 minute. 1TK("TK1") 1*TK("TK2") 2TK("TK3") 2*TK("TK4") 3TK("TK5") 3*TK("TK6") 4TK("TK7") 4*TK("TK8") 5TK("TK9") END ```` Cheers, Roger
12
4
2
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft