Best Practices for the Clickstream Sessionize Transformation

Backing Up PERMLIB

When the Clickstream Sessionize transformation has completed execution, any sessions that are still considered open have data stored in a permanent library that has the default libref, PERMLIB. This information is used to process the next Web log in a series when user sessions span across Web logs. The next time the Clickstream Sessionize transformation executes, if possible, a user's open session data in PERMIB will be combined with session data for that user in the current run. In this way, a complete record for a user can be captured across different runs of the clickstream job.
Make sure you back up the contents of PERMLIB before each execution of the Clickstream Sessionize transformation in a clickstream job. If the Clickstream Sessionize transformation should fail for some reason, and the tables in PERMLIB are in an unknown state, then the backup can be restored and the job can be rerun. The physical path to PERMLIB is specified in the library definition on the Options tab in the properties window for the Clickstream Sessionize transformation, in the Tables section.

Managing the Contents of PERMLIB

If you use a clickstream job to reprocess the same data multiple times, as you might do when developing a new clickstream job, be sure to return PERMLIB to the state that it was in before the last execution. If PERMLIB was empty, then its contents should be removed. If PERMLIB contained tables, then the tables should be restored to the state that they were in before the last execution. Otherwise, duplicate data appears in the output table for the Clickstream Sessionize transformation.
Use the Delete PERMLIB Tables option in the Tables section of the Options tab in the Clickstream Sessionize transformation to control how PERMLIB is managed. When you set the job up, this option is set to delete PERMLIB tables. When you are ready to run the job in production, this option should be changed so that session data is correctly connected across executions of the job. See the Help for the Delete PERMLIB Tables option from the options tab.