- 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
superfluous fr1st..
Admin
FIRST
Admin
Admin
TRWTF is that the second SQL statement is never executed.
Admin
I predict an explosion of comments concerning SQL injection and the merits of stored procedures vs. queries.
Admin
Admin
Admin
Why bother, the statement isn't being used any way ;).
But indeed it would have been a lot better if the statement were parametrized and it could probably have been placed in a stored procedure, which would have made it a lot more readable at the same time.
Admin
Well, it won't be me, I cannot get XKCD on my embedded system.
Dignissim: The official cult of Dig.
Admin
tut, tut, joins in the where clause!
Admin
As I've stated before, Visual Basic can die of gonorrhea and rot in hell.
Admin
The Real WTF is that someone is using Visual Basic, amiright?
CAPTCHA: vindico - akwardness, a sensation you are about to fail.
Admin
Admin
Admin
That's some wicked syntax highlighting.
And by "wicked," I mean "evil."
Admin
Right! Because you never see shit like that in Java or C++ or PHP or Python.
/sarc
Admin
Dead code peppered with old code that is commented out? Poorly written queries? This is WTF worthy?
Admin
captcha conventio: an Italian convention.
Admin
Hey! This WTF reminds me of this really awesome xkcd:
http://xkcd.com/327/
Oh little bobby tables. Look at the trouble your name has caused!
Admin
Oracle and SQL-92? Don't they need to support empty strings for that?
Admin
Really? I don't see how it relates at all. The article actually makes me think more of this Marmaduke:
http://comics.com/marmaduke/2008-03-29
Admin
Not a WTF. Obviously they're using some database that uses quantum values where dates can be both greater than AND less than the current date.
Admin
TRWTF is that you are somehow able to read and post here while being blind. pim.D_EFF and pim.D_INEFF are two different date fields.
Admin
Admin
captcha: damnum - latin for "DAAAAAMN!". See also: "DAAAYUUUM!"
Admin
So.... wtf is with that naming convention? I know the pseudo-Hungarian with "s" for string, "i" for integer, etc, but what's with the p and l? I see the "p" prefix fairly often in Classic ASP.... which is more often than I like to see Classic ASP due to the fact so many shit businesses here seem to think Classic ASP is a perfectly valid tool to use in 2010.
Param and Local?
Admin
Admin
Also TRWTF is of course not that the second query is not executed but the first one used to be only to determine the content of the second one (hence it's result set is closed afterwards) the second query is probably executed after this snippet. So the WTF is that there are two statements executed instead of one...
Regarding SQL Injection: Yes prepared statements would have been much nicer here, however we don't know if the input data to these queries can be trusted or not so assuming good faith the data is perfectly fine.
Admin
Er, sorry guys but if you read the article you will see that the tnsnames file wasn't on Lennart's workstation - it was on a network share but it got removed when he ran the uninstaller.
Admin
Where's the appendicitis? Assuming there's no exception-handling around this (in VB, I mean, what are the odds?), I suppose a couple of bad parameters would yield a SQL syntax error but that's about the worst I can see happening. At least they close the recordset....
This looks more like a coccyx than an appendix.
Admin
Admin
Appendicitis is in Appendix B, "List of Common Ailments".
Admin
TRTRWTF is that neither query gets executed.... and that ADO will bomb on the rs.Close statement
Admin
You may have missed this line:
Set rs = lconConnection.Execute(lsSQL)
Admin
... perfectly fine until the code is copy-pasted into a new application where the data is untrusted.
Admin
Ok, I guess it is time for me to finally write up and submit one of the best WTF moments in code... it too is vestigial code, but it does a lot of something yet accomplishes nothing.
Kind of like this post.
Admin
I guess my job is becoming a WTF - I see worse than this every day. Unfortunately my contract prevents me from posting it here.
Admin
I'm sorry...what?
Admin
Technically, the appendix also serves to soften the stool, much like this article could use.
CAPTCHA: capio, cap'm
Admin
mmm...soft serve...
That's it! I'm off to DQ!
Admin
Sure, but have you seen the underlying library?
Admin
I mean, my mom does call me ContraCorner does she?
Admin
Mmmm, sodomy...
Admin
Admin
Well played
Admin
This isn't Worse Than Failure. This is, at most, as bad as failure. Maybe not even that bad.
Admin
I have seen it to mean property also:
Dim p_VestigalOrgan As Organ
Admin
This is the funniest thing I've read on this site in a long time ;-)
Admin
I agree, visual basic should be allowed to have unprotected sex of all kinds with as many loose women as possible.
Admin
When did embedded systems gain access to network shares?