Logic enhancement

- Cleaned up iteration logic
- Updated function naming conventions for clarity and further
modularized functionalities
- Removed some test code.
Learn CMD - DB Insertion

Successful DB insertion if !exist in database.   Next commit will
include the appropriate insertion of relational indexes.