lundi 29 février 2016

How to convert UNIX timestamp into date without the time

I have a table full of UNIX timestamps and I want to strip the time and check againt the CURRENT_DATE and grab the total count.

$shippedCount = Model::whereRaw('DATE(UNIX TABLE) = CURRENT_DATE')->count();

What is the best way to go about this.



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/1LQh0yg
via IFTTT

Aucun commentaire:

Enregistrer un commentaire