starting with DB support and find the last business day and support for output file: