I've already talked about working with date and time values on both sides of the web stack. However, in web development, we not only manipulate temporal values, we often need to store them somewhere and retrieve them later. This post discusses the best methods of persisting dates and times in databases.
Testing your application against a real database and pseudo-real data is quite a challenge. I'm going to show you how to automate the process of creating a test database with its schema and filling it with data, all with tools you might already be familiar with, including Nette Tester and Doctrine 2 along with Doctrine Migrations and Data Fixtures.
I am a full-stack web developer from Brno, Czech Republic. I contribute to open-source projects, write a technical blog, and speak at meetups and conferences.