<div dir="ltr"><div><div><div><div>Hi list,<br><br></div>I've noticed that Comcast periodically updates the channels, sometimes replacing a channel with the Pacific feed, or sometimes replacing it with a different feed altogether. mythfilldatabase picks up these new channels but doesn't delete the old ones. I can't say I've experienced any problems because of it (no false recordings, etc.), but I do like to keep my database clean. So I found a nice SQL query that will identify those duplicated/replaced channels and then I can use mythweb to nuke them from orbit. Here's the statement to use:<br>SELECT channum, sourceid, COUNT(1) AS CNT FROM channel GROUP BY channum, sourceid HAVING COUNT(1) > 1;<br></div>Then just go through each of the channum entries and prune the extra channel.<br><br></div>Giving credit to <a href="http://www.tech-recipes.com/rx/49959/finding-duplicate-records-using-group-by-in-sql-server/">http://www.tech-recipes.com/rx/49959/finding-duplicate-records-using-group-by-in-sql-server/</a><br><br></div>Karl<br></div>