from datetime import datetime


def text_to_datetime(datetime_string):
    """
    convert text in sqlite3 database to python datetime object
    :param datetime_string: string in format MM-DD-YYYY HH:MM:SS
    :return: datetime object
    """
    return datetime.strptime(datetime_string, '%Y-%m-%d %H:%M:%S')