| « Prev | Page 1 | Page 2 | Page 3 | Next » |
|
I want to make a comment, but I got nothing.
|
|
I can see the point of this. Who knows when you might need to change the type of Nothing system-wide.
|
|
Once a great philosopher said:
You know, you come from nothing, you're going back to nothing. What have you lost? Nothing! |
|
My eyes, the goggles do nothing!
|
|
|
|
This is what they call "having something for Nothing"!
|
|
Love it!
Must be the database connection of the Nada software. :) |
|
TRWTF is that in oracle, '' is actually equivalent to null.
|
|
What's worse, if this is MS SQL Server, the engine treats that as a system stored proc and may spend additional time doing a lookup for it. So not only does it do nothing, it wastes even more CPU cycles than one might think.
captcha: ideo: It's not quite an idea, but sort of a bad thought. |
|
You get nothing for nothing, if that's what you do...
|
|
Soft coding the value of nothing is obviously to aid future maintenance. 'Nothing' is an entirely subjective quantity depending on your field of expertise (I'm looking at you, quantum physicists).
|
I get scared that this might be a whitespace program. |
|
"Money for nothing and chicks for free", i think the old coder had it figured out.
|
|
They probably had a meeting at some point at which the developer said "Nothing could possibly solve this problem!"
|
Re: sp_getNothing
2010-04-21 09:24
•
by
@Deprecated
(unregistered)
|
Then the real WTF is there are no comments. CREATE PROCEDURE [sp_getNothing] AS select '' as Nothing -- Bring on the chicks END |
|
More stored procedures you call the cooler you are. Ok?
|
Sure, just don't ever work on my team. OK? |
|
Obviously some overzealous senior architect required that all data access routines use stored procedures-- even when the result is "return null".
|
|
I would love to see a code snippet where this procedure gets called
|
Nah, I think that would have to be a different SP, something like this: CREATE PROCEDURE sp_Dire AS select cast('' as money) as nothing,'' as chicks END |
Cheer up Brian, worse things happen at sea! |
|
Oops; didn't read the "spec" properly. Should be
CREATE PROCEDURE sp_Nothing AS select cast('' as money) as nothing,'chicks' as free END |
Eric Idle? |
Come on! I can let you use some of my cool stored procedures! |
|
System.out.println("Hello World!");
Actually, scrub that. System.out.println(""); Fixed. |
|
Ah, yes, I see the problem. It should have been implemented as a UDF instead of a Stored Procedure; the way it's done now, the result has to be selected into a temporary table. A UDF version could be used with SELECT and WHERE statements for queries that depend heavily on nothing.
|
|
You'll get nothing and like it!
|
|
"The only true wisdom consists in knowing that you know nothing"
"Dear subconscious this is an important message, give me all your monies and chicks" "" |
Re: sp_getNothing
2010-04-21 10:23
•
by
Some guy
(unregistered)
|
Where can I get some damn bait? |
This is the result of getting paid per line of code. He got money for Nothing. |
|
"You get NOTHING! You lose! Good day, sir." Gene Wilder as Willie Wonka.
|
|
Clearly this is a placeholder for where features would potentially be added later or where it had been removed but the surviving code still needed an answer.
|
|
This stored proc solves a problem I've had for the past 7 months! TY TDWTF!
|
|
Not completely true.
In 2008 the user database is searched before master is so there is no performance penalty by using an "sp" prefix ... although, in my opinion, it's good practice not to. Cheers! |
Re: sp_getNothing
2010-04-21 10:47
•
by
Anonymously Yours
(unregistered)
|
//Management bastards keep saying we do nothing all day, huh? |
|
Where's the WTF?
> this specific stored procedure was used 13 times within the application. How? |
Don't you mean
|
|
It was an app to support a CEO's staff meeting? Seems like this would be a function that would be used often...
|
|
|
Possible usage of sp_getNothing:
parameters.Add("UserID", UserID); switch(whatToGet){ case GetThis.UserID: spname="sp_getNothing"; break; case GetThis.Name: spname="sp_getName"; break; case GetThis.DOB: spname="sp_getDOB"; break; case GetThis.FileID: spname="sp_getFileID"; break; default: spname="sp_getNothing"; break; } comm.CommandText=spname; etc... This is still bad practice. |
don't run it, it's "rm -rf /" |
|
There's nothing good unless you do it yourself.
|
|
So, the programmer that wrote this got paid for doing nothing.
Or that he was good for nothing. I'm not sure, but sp_getNothing facillisis both situations. |
Re: sp_getNothing
2010-04-21 11:56
•
by
Dr. Goodnight
(unregistered)
|
You wouldn't happen to have identified that this is the way Oracle works by using SAS SQL/Connect would you? |
what does that do, and how do I run it? I'm feeling dangerous... |
Re: sp_getNothing
2010-04-21 12:03
•
by
Dr. Goodnight
(unregistered)
|
Hey, this is fun. |
|
ditto
|
|
ditto
|
| « Prev | Page 1 | Page 2 | Page 3 | Next » |