Issue with SSIS C# Code for derived date

Hi Guys, I am a C# noobie here and I am trying to convert a date in my flat file that is shown as 12-Jan-2013 to mm-dd-yyyy. I was trying to use

public override void Input0_ProcessInputRow(Input0Buffer Row) { DateTime varDate; bool isParsed;

isParsed = DateTime.TryParseExact(Row.Column0, "dd-MMM-yyyy", System.Globalization.CultureInfo.InvariantCulture, System.Globalization.DateTimeStyles.None, out varDate); 

But it is now dumping '1899-12-30' into every new cell. Any idea what I am doing wrong here?

by geo845 via /r/csharp

Leave a Reply