Topic
  • 3 replies
  • Latest Post - ‏2014-01-15T16:31:32Z by Matthew_Simons
Rashmioptim
Rashmioptim
5 Posts

Pinned topic Optim File Attachments Deletion

‏2014-01-06T07:36:27Z |

Hi,

We have project in which we are required to delete some Siebel file attachments from the Siebel CRM system but the associated row in the S_XXX_ATT table should not be deleted.

I am aware we can archive and delete file attachments associated to a database table and we have this established for our Siebel system currently. But now, the requirement is to only delete the attachment after archival and the row of the table should remain in the db.

Is there a way Optim can handle this?

We are using Optim 7.3.1. and Oracle 10g , Siebel 8.1

Any quick response would be appreciated since we have to get back to our business soon.

Thanks,

Rashmi

 

 

 

Updated on 2014-01-06T09:55:45Z at 2014-01-06T09:55:45Z by Rashmioptim
  • Robert Phillips
    Robert Phillips
    5 Posts

    Re: Optim File Attachments Deletion

    ‏2014-01-06T13:07:15Z  

    I may not completely understand what you are trying to do.  I am assuming that you are archiving rows that contain a filesystem path address for a "file attachment" and that, after the row is archived, you wish the filesystem path in the row to be nulled out and the file to be removed from the filesystem.

    This may not be the most efficient way to do this, but one could use Archive Actions to construct a "candidate table" of archived rows with file attachments as the archive/extract is performed, and then use that candidate table as input to an SQL statement that nulls out the filesystem path in the row in the DBMS, and as input to to a delete/rm script that removes the files from the filesystem.

    Someone more experienced with field operations and with Siebel may provide a more efficient solution, but I hope this will get you started.

  • Rashmioptim
    Rashmioptim
    5 Posts

    Re: Optim File Attachments Deletion

    ‏2014-01-07T03:14:46Z  

    I may not completely understand what you are trying to do.  I am assuming that you are archiving rows that contain a filesystem path address for a "file attachment" and that, after the row is archived, you wish the filesystem path in the row to be nulled out and the file to be removed from the filesystem.

    This may not be the most efficient way to do this, but one could use Archive Actions to construct a "candidate table" of archived rows with file attachments as the archive/extract is performed, and then use that candidate table as input to an SQL statement that nulls out the filesystem path in the row in the DBMS, and as input to to a delete/rm script that removes the files from the filesystem.

    Someone more experienced with field operations and with Siebel may provide a more efficient solution, but I hope this will get you started.

    Hi Robert,

    Thanks for your response. Yes, you are right, we are trying to only remove/delete the file attachments from the Siebel File system but the associated row should remain in tact. So we can't use the Optim Delete request for this since it would delete both the table row and the file attachment linked to it referring to the archive file.

     

    So as you have suggested , I would have to go for another way of deletion for the file system using shell scripts and SQL and Archive actions.

  • Matthew_Simons
    Matthew_Simons
    27 Posts

    Re: Optim File Attachments Deletion

    ‏2014-01-15T16:31:32Z  

    Hi Robert,

    Thanks for your response. Yes, you are right, we are trying to only remove/delete the file attachments from the Siebel File system but the associated row should remain in tact. So we can't use the Optim Delete request for this since it would delete both the table row and the file attachment linked to it referring to the archive file.

     

    So as you have suggested , I would have to go for another way of deletion for the file system using shell scripts and SQL and Archive actions.

    You are correct, shell scripts/SQL would be the way to go if the attachment is stored outside the database (as opposed to in the database as some sort of Large Object).  Using an Archive Action to write out the pointer to a table would help you to construct the script/SQL to locate the appropriate objects to be deleted.

     

    Hope that helps!

    Matt