Converting DateTime to string for SQL operation.
Fix bug about 0 value not inserted.