Delete Specific Document types from the TN database

Hi,

I want to delete specific document types from the TN database in a specific time period and there is a service in TN package wm.tn.archive.extendedArchive but which is used for delete only one document. Is there any alternative for delete bulk document types in specific timings.

Could you help me ASAP.

Venkat

Venkat,

you can use “wm.tn.doctype:delete” to delete any specific document from trading network but I am curious what is driving you to this approach and deleting TN documentType at runtime isn’t the best thing.

Talha Khan,

You haven’t get my exact requirement that after receive the documents into TN then I want to delete some particulor documents after some specific time period.

You have suggested “wm.tn.doctype:delete” service but it wont work for me.

Thanks,
Venkat Chekka

You may want to investigate the services in wm.tn.archive in more detail.

The extendedArchive service accepts a docTypeId as input, which I assume you’ve seen. If there is more than one type of document that you wish to purge, then call the service for each docTypeId you want to purge.

Side note: For extendedArchive, the description of the docTypeId for XML documents seems awfully weird. And the other parameters seem poorly documented. Are they all required? If so, that’s a significant limitation IMO. Also, specifying an external ID without a qualifier for the senderId and receiverId seems odd and risky. Anyone have hands on experience with this service? Is the service doc off?[FONT=Arial Narrow][SIZE=4]
[/size][/font]

Hi reamon,

I want to delete all documents using single servcie if use one service for delete the doc then will be more services needs to be use for deleting all the docs as per your suggestion.

Thanks,
Venkat

Create 1 service, and schedule it to run daily, weekly, whatever.

Within it, call extendedArchive multiple times.

My problem was cleared, Thank you all,

Can you share what you did?

I have created one scheduled service and which is calling extendedArchive service multiple times for deleting the TN document types.