You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Current »

The SQL for purging L1 data is:

SELECT 
    count(DATA_CATALOG_ADMIN.PurgeDatasetVersion(DatasetVersion))
FROM 
    DatasetGroup g 
JOIN 
    VerDataset d 
    ON 
    (
        d.DatasetGroup= g.DatasetGroup
    ) 
JOIN 
    DatasetVersion dv 
    ON 
    (
        dv.Dataset= d.Dataset
    ) 
WHERE 
    g.DatasetLogicalFolder=39684091 
    and d.LatestVersion != dv.DatasetVersion 
    and Registered<sysdate-14

This does not actually delete data, it just puts it into the "to be deleted" table – DATASETLOCATIONPURGE. This is now run automatically as an Oracle "cron"-job.

To actually delete the files the script in ~glast/datacat/prod/delete-datacat must be run (on glastlnx21). .

  • No labels