and what comes out the other end > A STRING. I entered (DT_DATE)(SUBSTRING(ImportDate,1,4) + "-" + SUBSTRING(ImportDate,5,2) + "-" + SUBSTRING(ImportDate,7,2)) to convert the string to date. Secondly, you would like to be to ACTUALLY convert the data, once again SSIS falls down. Firstly, if you have a file the size of mine(150 fields), you would expect to be able to order your incoming columns. One would be forgiven for thinking it would just be a matter of passing the string to a expression in the DerivedColumn component. This is where the real problem just start. Fair enough, for some bizarre reason SSIS cannot deduce a date from that format and we are forced to reformat the string to yyyy-mm-dd. The first field is called ImportDate and its format is yyyymmdd. As an example, I have a text flat file source with over 150 fields. Im finding the SSIS UI very confusing and the Help files even more so. OK - Ive now spent the best part of 2 days trying to convert a string date to a date datatype.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |