integration with CAS and sql, keeps history and auto-loads