Hi NogDog,
Was hoping for a bit of assistance.
you mentioned the following:
If you combine FROM_UNIXTIME() with DATE_FORMAT(), you should be able to output it in pretty much any format, e.g.:
Code:
SELECT DATE_FORMAT(FROM_UNIXTIME(`date_col`), '%e %b %Y') AS `date_formatted` . . .
I have a similar situation, but goes one step further: i'm using a SELECT COUNT query in order to setup pagination, and this query I have works great and returns all results it should:
SELECT COUNT(DATE_FORMAT(FROM_UNIXTIME(`date`), '%Y')) AS `buzzyear` FROM `buzz` WHERE `showPublic` = 'y'
However, I need it to only return a count of those rows which I specify for the year, which I get through PHP, like so:
$year = $_GET['year']; //this is what we want SQL to return
$query = "SELECT ...";
Can you point me to the mysql function I could use in conjunction with this?
Thank you very much!