Page 2 of 2

Posted: Fri May 09, 2008 2:21 am
by tsn
why you are getting NULL, because the output link consider the date input as string and while writing it is trying to convert to DATE, fails to convert and NULL was passed to output.

Can you check whether any ^M character in the EOR and check whether length and display are given correctly.

still if you get the NULL, the place a transformer before sort. use iconv to convert the date into number, place sort stage, sort it, and then place a transformer. use oconv to convert to date format and then write it in the file

Posted: Fri May 09, 2008 2:36 am
by ArndW
My test file just had 1 column with a date in the format dd/mm/yyyy. I declared it as type "date" and sorted it, then output it as type "VarChar" to another sequential file.

When I changed the output to "Date" as well I get the following warning:
TestServerSort..Sort_4: At row 1, link "DSLink5", while processing column "In.String"
Value treated as NULL
Attempt to convert String value "01/01/2007" to Date type unsuccessful
Perhaps you could have mentioned that warning in your initial post, it would have saved much writing and effort.