Duplicate a Mysql Database – Tutorial

Duplicate Mysql Database

Learn how to duplicate a mysql database in 2 simple steps. Many a times, you want to duplicate a database to create a backup, to test against real data or just because you want to. Lets quickly checkout how this can be done step-wise. We will be using the command line utility to duplicate the … Read more

Configure Doctrine Multiple target entities

Configure Doctrine Multiple target entities

Many developers are often plagued with questions of the best possible way to handle inheritance mapping or configuring multiple target entities in doctrine. How does one do that? Lets go over a slightly different scenario first to understand the real problem better. Lets say you have 2 entities with their respective fields: Person (id, name, … Read more

Get Random rows in Doctrine

random rows with doctrine

Every Php Symfony developer knows the struggle of getting random rows/records via Doctrine. This is because there is no native solution present and quite unfortunately, the doctrine team isn’t even willing to implement this feature! (Reference) So how could we get random rows/objects? Lets go over the possible options, each having its advantages & disadvantages … Read more