hcg |
17 Comments | 
Jan 24, 2007 Do you love me less knowing that this is what I do all day?
select case when ne_pa1 . pallets is null then 0 else ne_pa1 . pallets end, case when ne_pa1 . ship is null then 0 else ne_pa1 . ship end, case when ne_pa1 . wgt is null then 0 else ne_pa1 . wgt end, case when ne_pa1 . need is null then 0 else ne_pa1 . need end from( select trunc (( a . pa +( c . pa /( sum_pa - sum_pa_minus1 )*( input_qty - sum_pa_minus1 )))/ b . unitsperpallet , 0 ) pallets , a . pa + b . unitsperpallet *( trunc (( c . pa /( sum_pa - sum_pa_minus1 ))*( input_qty - sum_pa_minus1 )/ b . unitsperpallet )) ship , ( a . pa + trunc (( c . pa /( sum_pa - sum_pa_minus1 )*( input_qty - sum_pa_minus1 ))/ b . unitsperpallet )* b . unitsperpallet )* b . wgt wgt , c . pa -( b . unitsperpallet *( trunc (( c . pa /( sum_pa - sum_pa_minus1 ))*( input_qty - sum_pa_minus1 )/ b . unitsperpallet ))) need from ( select case when pa is null then 0 else pa end as pa from ( select sum ( qty ) pa from stsc . planarriv where item = input_item and dest = 'NE' and source = input_source and trunc ( schedshipdate ) <= trunc ( sysdate + t - 1 )) ) a , (select wgt , unitsperpallet from stsc . item where item = input_item) b ,(select case when pa is null then 0 else pa end as pa from ( select sum ( qty ) pa from stsc . planarriv where item = input_item and dest = 'NE' and source = input_source and trunc ( schedshipdate ) = trunc ( sysdate + t )) ) c ) ne_pa1 ;
I think I just threw up in my mouth a little bit.
Reader Comments (17)
I am so hot for you right now.
luv you even more!! for cracking me up!!!
What. the. fuck? LOL
... and I thought my head hurt from all that school crap being stuffed into what space was left in my brain today. Geesh.
Nah, it'll take more than SQL for me to dislike you.
...Though I have to say that is some hardcore SQL there...
But do you do it naked?
I don't know what all of that is...would you like me less because of that?
Me<---------------not quite tech savvy!
Define "love"
"Doe [sic] you love me less knowing that this is what I do all day?"
IFF this code supports an evil machine. :-) I surmise from the choice of SQL vars that it's for shipping/inventory/warehousing or somesuch. Given the personal commitment required to overcome the creeping boredom, respect points just went way up, Bonus points for sympathy if this code is destined to be interpreted by a Microsoft product.
No less love. If anything, more. Even though your first-word typo reminded me of Dan Quayle.
Joe-You need help. ;-)
Rachel-Funny, if it weren't so sad.
Mel-I drink a lot. It helps.
Grax-Yeah, I am hardcore.
Avitable-Not usually. That would somehow be even sadder, I think.
Ling-No, it makes me love you more.
Timmy-Nah. You would only love this if you placed me here and were making fat commissions every hour I worked. But no more for you...in house HR?! I have my sources.
Brad-Typo? Hmm. I have no idea what you are talking about.
I think it would be hotter. Especially if there was a donkey around.
You just reminded me of why I changed majors in school.
Yeah, I know. But I like being me.
Wow, would love to know your sources....
It's not a secret, but didn't know we were in the same professional (and I use that term loosely) circles.
Were you called about me? Did you lie and say good things? How much do I owe you?
Shame about the bug in line 12.
Um....
gulp...
Um... can I please be excused? I left my homewo...oh - there isn't gonna be a test. Oh - well then - never mind.
Farty-I will squish your bugs.
Jali-No test. Swear. You're cool.
I am in total agreement with Russ . . . code was always my nemesis. I'm running for fear of my life. You are the coding queen.