Activity attachment fields

To support the activity attachment feature, the following fields in the Activity_Attach table are used:

Column name Data type/size Description
ACTIVITY\_SEQN long integer Used to store a reference to an associated activity record
FILE\_NAME varchar (255) Attachment's file extension
FILE\_TIMESTAMP Datetime Date the attachment was last modified
ATTACH\_IMAGE image File's binary data
INTENT\_TO\_EDIT varchar (40) Indicates whether a user has started an edit operation (Date/Time + “#” + )
READ\_ONLY Boolean Indicates whether the attachment is available for editing by non-administrator users

To purge activity attachments created before a specified date

To delete activity attachments with a timestamp before a specified date, you must modify the Purge old Activity attachments report spec to include a date in the purge script from which you want to delete activity attachments, and then run the purge script.

📘

Note

You must have an authorization level of 8 or higher to modify a report spec.

📘

Note

The FILE_TIMESTAMP date that you modify in the purge activity attachment script refers to the date that displays in the File Date column on the Activity Attachment window for the attachment. The File Date displays the date the attachment was last modified. However, if the attachment has not been modified, the date that displays corresponds to the date the file was created.

  1. Select Utilities> Report Specs to open the Report Specifications window.
  2. Scroll down to the SYSTEM module.
  3. Select the SYSTEM-Purge-Purge old Activity attachments report.
  4. Click Parameters to open the Detail Report Parameters window.
  5. Click Edit.
  6. Using the format YYYYMMDD, modify the FILE_TIMESTAMP value of the Purge old Activity attachments script. In the following example, the script has been modified so that activity attachments with a File Date earlier than October 10, 2002 will be deleted:
    delete Activity_Attach where FILE_TIMESTAMP< '20021010' and ACTIVITY_SEQN> 0 and READ_ONLY=07. Click Save.
  7. Select Utilities > Reports and Queries.
  8. Select Purge from the Report Types scrolling list.
  9. Select Purge Old Activity attachments from the Available Reports scrolling list.
  10. Click Run. A message displays informing you that you should make a backup of your database before running the activity attachment purge utility, and asks if you want to continue running the utility. Click Yes to continue running the utility, or No to cancel.
  11. The Purge old Activity attachments window displays showing the number of attachments that were deleted from the idatabase.
📘

Note

In an environment where users are importing activities simultaneously, you must ensure that the users do not attempt to import the same files or run the same queries. To prevent a user from inadvertently affecting records another user is processing, you can limit access to the advanced Activity Importer features so that processing is restricted to records imported by a user's specific session.