Parse datetime to 'undefined' if string representation either "undefined" or "null".