Handling of date columns

Hi,

I have the following question: I wanted to apply Rule Engine node for one column with dates, for example, all dates which are greater than 01.05.2012 mark as 1 and remaining mark as 0. But I got an error message that date is not numeric column (the needed date column was initially in string format). I tried to use String to date node but it didn't help. I want to use dates for different calculations, what should I do to put KNIME read dates properly?

 

Thank you in advance.

The string to date node should be the way to go. You need to provide the exact format of the date in the node.

simon.

Or you can use the 'time difference' node, and set the reference time to 01.05.2012, then positive differences will be before and negative differences after that time - you can then use these in your rule engine or java snippet (return ($time_diff$>=0)? 0:1;).  You can set the time unit the comparison is in - you probably want 'days' in this case.

Steve