I have a function that consumes a datetime string that is returned from a DB query. Right now the query returns a datetime object.
What I am looking for is what would be the preferred way to create my datetime string. I have not done any performance profiling yet, just looking for previous experiences from people.