pymydb.execute( '''SELECT host, ref, location, useros, browser, visits, hits, 
downloads, authuser FROM guests
                                        WHERE pagesID = (SELECT ID FROM pages 
WHERE url = %s) ORDER BY visits DESC''', page )
        data = pymydb.fetchall()
        for visit in visits:
              visit = visit.strftime('%A %e %b,  %I:%M %p')


'visit' is being returned from database containing a MySQL datatime field that 
i want to change to another format which is ('%A %e %b, %I:%M %p') thats why 
i'm using that function. If not convert or comment out then results are not 
appearing normally.
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to