SQLTeam.com | Weblogs | Forums

Convert string to datetime OPENXML WITH



I am importing data from xml. I receive a string that needs to be converted to datetime. How do i implement it? If i write as below it throws an error that it can't convert varchar to datetime.
I need to add convert and not sure of where.
OPENXML(@hDoc, '/ROOT/Funds')
[insertion_date] [datetime] 'insertion_date',



You should go this one, it may be helpful to you. https://phe1129.wordpress.com/2007/03/16/convert-xml-datetime-xsdatetime-to-sql-datetime/