I have now changed the date time to be converted to date but I still get the following message:
Conversion failed when converting date and/or time from character string.
-- 9 - Populate the #ParsedFileList table with the final data
--INSERT INTO #ParsedFileList
--(DateTimeStamp,
-- LSN,
-- FileSize,
-- FileName1)
SELECT --LTRIM(SUBSTRING (Col1, 1, 20)) AS 'DateTimeStamp',
CONVERT(datetime, col1) AS 'DateTimeStamp',
LTRIM(SUBSTRING(Col1, 71, 6)) AS 'LSN',
LTRIM(SUBSTRING (Col1, 21, 18)) AS 'FileSize',
LTRIM(SUBSTRING (Col1, 40, 1000)) AS 'FileName1'
FROM #OriginalFileList
ORDER BY LSN
Thank you!