Fixing bugs

Fixed a number of bugs that prevented the example from running in a
fresh environment.
Current directory is now picked up in RunAll.bat.
The metadata model now has all the attributes it should have.
Changed historization to datetime2(7) as some jobs ran so fast a
datetime had too coarse granularity.
Errors will now propagate (thanks to THROW).