Yeah, you must use colons instead of dots in the time. I'm used to seeing either one ... but SQL isn't.
SELECT CAST('20180326 05:00:00' as datetime2)
SQL DBA,SQL Server MVP(07, 08, 09) A socialist is someone who will give you the shirt off *someone else's* back.