Occasionally, the question comes up about how to clear/reset the surrogate key file from the Linux command line. It is a simple process really, but it should be done with care and, only, if you need the keys in the dimension to be reset to the beginning. A complete reset would require:
- The target table to be truncated and,
- All keys in use in facts to be removed, or reset after the fact, and/or the table truncated and reloaded,
- The Surrogate Key file emptied, and
- The ETL rerun.
- cat /dev/null > <<FileName>>
- cat /dev/null > Season.srky