I need to imagine the execution time of tasks in my MySQL 5 database.
Then I need to store such moments:
_ eighteen
_ 9:15
_ 12:00
Now I am in a dilemma whether to use a time data type or just a 4-digit integer, since I just need to store hours and minutes.
In the second case, I would save:
_ 1800
_ 0915
_ 1200
What are the implications of both approaches?
Which solution would you take, given that the most important requirement is high performance in a huge data set (millions of rows)?
The application code is written in PHP.
EDIT: I was thinking about an important point. If I use integers, I need to do some string manipulation with PHP when I show the time (to insert a semicolon), which probably resets the gain using integers
Thanks,
Dan
performance mysql
dan
source share