Invision Community 4: SEO, prepare for v5 and dormant account notifications Matt November 11, 2024Nov 11
Posted April 14, 20169 yr Hey guys, Anyone good with mySQL commands and PHP? My server is currently running PHP 5.6.19 and MySQL 5.16.29... I basically need to run a query with the following criteria: UPDATE ipb_core_attachments SET attach_hits = some numeric value (ie. $downloads) WHERE attach_ext = mp3 AND attach_date = LESS THAN 30 DAYS What I find odd is that attach_date is being stored as for example: 1458181690 Is that an Unix stamp? Does anyone know how the query command should be written in order to accomplish the above in PHP and MySQL? I came up with something like this: $Query = "UPDATE ipb_core_attachments SET attach_hits = ".$downloads." WHERE attach_ext = 'mp3' AND attach_date = < 1 MONTH; Bugt not sure if this would work.
April 14, 20169 yr https://dev.mysql.com/doc/refman/5.6/en/date-and-time-functions.html#function_unix-timestamp
Archived
This topic is now archived and is closed to further replies.