I am working on a Sybase ASE (migrating to 15.7) data purge utility to be used by multiple tables/ databases to delete huge amount of unwanted older data.
- After receiving an input table name, automatically figure out the child tables and delete data. But, I couldn't find an hierarchical query clause like Oracle's "Connect by .. Prior" clause. Is there any other way to implement this?
- I am deleting data by looping through multiple transaction/ commits in small increments. After the deletes, at what interval, should I do "reorg rebuild"?
- Do I need to do update statistics? If I have to, what is the criteria that I should consider before doing update statistics?
- Some tables may be partitioned. Is there anything that I need to consider in partition's perspective?
- Some of our DB's (i guess index..?) are clustered. I don't have much idea about clustering. Do I need to consider anything in clustering perspective?
- Send Email at the end of processing. Does built-in email package similar to oracle's UTIL_SMTP?