The Daily WTF just cracks me up sometimes . Todays code sniplet, Yet Another "Hex To Ascii", is a perfect example of how a simple task can be made complex with goto. It is difficult to be the worst though as this example shows: look at me, I know how to write loops.
One of the worst sql statements I have seen in a production environment does a simple date filter:
CREATE VIEW dbo.V_News_DetailsASSELECT TOP 100 PERCENT dbo.Details.idDetail, dbo.Details.sTitle, dbo.Details.sText, dbo.Details.dValidFrom, dbo.Details.dValidTo, dbo.Details.dNewsHour, dbo.Details.dValidHour, dbo.Details.idService, dbo.Details.lPos, dbo.Details.idImage, ...