MySQL class 0.2

During March I wrote a post about a simple class that I use when I need to communicate with a MySQL database in PHP 5.
Now it’s time to release version 0.2 of that class.

There are two changes from the past version:

  1. some bugs fixed;
  2. added a new method named “count“.

The new method is designed to count the occurrences of “something” “somewhere” so when you need to do something like:

SELECT COUNT(some columns) FROM some tables WHERE some conditions;

you can simply type (assuming you have created a $database object before):


$database->count("some columns", "some tables", "some conditions");

Enjoy!

Download the MySQLDB class source.

Related posts:

  1. MySQL class 0.1
  2. Page class
  3. ArgumentList 0.2.1

Tags: , , ,

Leave a Reply