- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
sob
Admin
Probably took longer for the server to run the query than it did to write it.
Admin
These last two posts have made my head explode explode explode explode explode explode explode.
.
Admin
My god. That second screen looks like some massive treasure room in Rogue. Look at all the rings and weapons!
Admin
if you play the query backwards it's a message from Satan.
Admin
O_o
Oh my hat.
I will never, ever complain about the WTF-ery code that I have to work with after seeing this.
Admin
That is pure insanity.... There are some WTFs that are inexcusable and downright stupid but that...
That is when you clear your desk and walk out the door; to hell with the breach-of-contract law-suit.
Simply claim irreconcilable differences… all the rage in celebrity marriages these days.
Admin
Give the guy some bonus points for thinking outside the box. You can't find this stuff in "SQL for Dummies" (I hope).
Admin
THIS one flew over the sql developper.
--Tei
Admin
liar ... that is not possible, venting must occur everyday at 5pm
Admin
I could see the manual ...
step 1: Click on Button X
step 2: take a half hour walk .. the results may or may not be there. But if the server crashes because of you clicking Button X you are Fired!
step 3: Have fun and enjoy your brief stay with us at Initech.
Admin
And forwards too.
Admin
You know, the bright side of this, you can show the screenies from today and yesterday, and regardless of the tech savvy of your boss, probably get an ok for a complete redesign of the database and little pestering for a while.
The ignorant will wince, and run away from reading the babble, while the knowledgeable will wince, and attempt to "kill it! Kill it with flame!"
Admin
Oh my god! I have watched this site for a while, but until now I didn't find anything so wtf what would justificate posting this "omg" posting here.
- Garo
Admin
To be honest, I can't see a sane way of querying the abortion of a database "design" without doing all that.
At least the gnarly join is being reused / separated out for reuse. Not sure all the brackets are necessary, but hey. Presumably they are all left joins because any or all of them can return null.
It's about how I envisaged it, having seen the previous WTF, to be honest. Better, in fact; I was expecting it to look more like this:
In fact, I wouldn't have bet money against all the join columns being converted to strings before the comparisons.
On the other hand, how someone who knows what a "join" clause means could write this without screaming in pain, and then refactoring the whole thing, boggles me.
Simon
Admin
Uhba debhada. Dashbidiboo da decklo shup. Reftinda kloptos abidi weng jehn! Dashnaka jibidenk, deb dlorpa jib.
*whack*
*bang*
*thud*
Oh, geez... what happened... oh, I was readding today's wtf... ok, uhh....
... next screenshot.... clarify things.... networkingJoin = ....
*fizzle*
Error: Mass system failure. Please restart brain.
Admin
Oh man, I worked for those DBAs. They would NEVER let you add a new field. Apparently something wrong with postgresql and alter statements (although nothing I ever found in the postgres docs, and nothing I could replicate on a local dev database). Just use the current table. Oh hey, we have a field called billing_code free. Would that work for your email address? They also liked to have really short fields, because we all know that first names are 10 characters long, right?
Admin
Reminds me of one of the databases I inherited recently.
The entity table for the properties that we manage contains a column called "Region", which is a nice FK to the Region table. So far so good. But then I noted another column on the Properties table, also a FK to the region table, called: "Real Region".
And, of course, the two columns had differing values .....
Admin
I never knew what it meant to "gibber" until I read this column. The title of the H.P. Lovecraft story "At the Mountains of Madness" fits pretty perfectly for today and yesterday.
Where's my shoggoth smiley?
Admin
You know, I ran into someone like that on IRC the other day... Basically claimed that altering tables was unecessary because once the design is set, you shouldn't have to change it.
I guess some people never make mistakes? Never have the customer change their mind. yeesh.
Admin
<FONT face=Arial size=2>It could be worse. At least they called it strEmailAddress. They could've called it strJobTitle.</FONT>
Admin
Well, at the least, here's Hello Cthulhu [image]
Admin
Two ways to think about it, one is that you should always be prepared to modify the schema, but at a cost (usually high) and two, if done correctly, a schema should be tolerant to additional idea without the need for modification - i.e. the changes are data, not metadata.
that being said, most database designs I have seen are neither. They all desperately want to be reworked.
Admin
Looks like some of the Lisp programs I've seen.
Admin
I usually vent all day on web sites while being paid to do work.
Admin
Admin
If you play it forward it's a message from satan just the same
Admin
paul is dead miss im miss im
Admin
I make it home by 5 pm, so my venting at bad code is done by then.
I did do a lot of venting on a mailing list about the total bass-ackwards code I inherited that was written in ColdFusion by someone who doesn't even remotely qualify as a programmer. I've been rewriting the website in ASP and somehow managed to compile a batch of 20 pages (and over 5000 lines of "code") into 4 pages and 400 lines.
I've since given up venting about it. I just sigh, hang my head, and plug on, content in the fact that while I've never really considered myself a "programmer", I'm Bill-Bloody-Gates compared to this weeniemaster.
(BWA HA HA! I just scrolled down to hit the captcha test and the word there is "billgates"! No word of a lie, I didn't even see that until I wrote the above! Hee! I amuse me!)
Admin
I wonder how much money they spend on maintenance cost.
Looks like this one evolved from a little WTF over the years to become a MONSTER WTF.
Admin
I'll be right back, I have to go wash my eyes out with acid.
Admin
Lol, like the Two Stooges of forum posts!
Admin
Jake deserves a medal for even touching this long enough to get it posted on TDWTF!!
Admin
Oh man... I think I'm gonna throw up...
Admin
Amen to that!
Admin
Lisp programs are usually indented and somewhat readable though.
Admin
Too familiar. I took over one that was 20Mb of 50-times copy-and-pasted Javascript and text-as-images. It was under 2Mb by the time I finished. But let's not complain - at least there are some people out there who are prepared to invest time and money in producing something maintainable.
Admin
Let's try that again ...
I already did.
--Doug (trying for his own WTF by not comprehending how to properly respond)
Admin
It's a good thing they weren't running on SQL Server 6.5 or earlier. It had a limit of 16 tables in a query (including those from views), and I count something like 20. Of course 6.5 didn't have ANSI join syntax, so it would have been shorter with *= instead of LEFT JOIN.
Admin
I am crying for you Jake.
Admin
You think you're funny. That's the concensus where I'm employed.
Oh, and Security said no Hibernate b/c the app may core dump and reveal sensitive information.
What is the smiley for crying/weeping? Google says this:
:'-(
CAPTCHA Test: jiggles (that's hot!)
Admin
<font face="Verdana" size="2">I am not going to <font color="#ff0000">burn</font> anyone else's brain by making them see any of this any more.
Just be thankful that there are still people in the world who do write like this. They keep those of us who are professional gainfully employed at good rates....
CAPTCHA Test: null
</font>
Admin
Woah, this is what Jake's previous post mentioned as "beautifully written, well-commented ASP"? THIS?
Admin
Back! Back, ye demon schema from hell! Go back to the flames from whence ye come!
:waves cross-shaped necklace around a la The Exorcist:
Admin
The code DOES look similar to what I thought it would be like, but WHY do they have to link EVERYTHING? They should only link what they use. And YEAH, the idea of misnaming fields is bad. SAPs ideo of generic names, or sequentially named fields is even probably better. And the parenthesis aren't needed.
Steve
Admin
That's just what you get for adopting 'one table to join them all' approach. I don't think the query is a major WTF in itself, but rather a logical result of the totally insane database structure. Apart from the 'no views' argument, it seems there is no easy way to query this heap of randomly connected tables.
So, it's easy to say some people should be prevented from using a database at all. But then they would revert to xml or flat-text, much more wtf-ish. At least there are tools for refactoring a faulty db design. So we should be grateful, it could have been worse.
Admin
Ahhghfphflt!
Brain. Failed. To. Parse.
Admin
<font color="#000000"><font face="Courier New"><font size="2">networkingJoin = "(((((((((((((((((Cn LEFT JOIN CnAdr ON....
<font face="Times New Roman" size="3">Step 1: Remove one parenthese
Step 2: Walk away quietly.
...
Step 3: Hilarity ensues
</font>
</font>
</font></font>
Admin
6.5 does have ANSI joins.
Admin
I suppose the database is MS Access and therefore brackets in join clause are necessary.