Wednesday, April 08, 2009

schedule update flushing

The schedule update was consistently timing out every time the csv update was done. Checked with Plesk DBWebadmin (phpmyadmin) and found records from 2008 onwards. Blundering about the interface, found a "Search" - tried 2008, it gave
Search results for "2008" (at least one of the words):

336232 match(es) inside table radiosai_stream_daily Browse Delete
Blundering, because I chose delete, and it did
SQL-query: 
DELETE FROM `radiosai`.`radiosai_stream_daily` WHERE `streamId` LIKE '%2008%'
OR `fileId` LIKE '%2008%' OR `groupId` LIKE '%2008%'
OR `gmtDatetime` LIKE '%2008%' OR `newflag` LIKE '%2008%'
At least now I know what to give as the proper SQL statement - something like
DELETE FROM `radiosai`.`radiosai_stream_daily` WHERE `gmtDatetime` LIKE '%2009-01%'

No comments:

Post a Comment