Various enhancements; worked on table creation logic