add sql commands which are already applied to prod
I noticed that I forget to create a PR for this changes after rebasing my dev branch. This changes are already in production. The modifications:
- added a foreign key to the jobs table
- set the insert time stamp for the future (when we insert a run to the db, it can take very long (~2 minutes). We make sure that we do not miss files.