PDA

View Full Version : Just a little humour



Dan Mages
04-24-2004, 6:17 PM
>SELECT * FROM home depot employees WHERE clue >0



0 rows returned

Dan :D

Aaron Koehl
04-25-2004, 1:40 PM
Heh :)

Error in SQL syntax before token 'depot'.

SELECT * FROM home_depot_employees WHERE clue > 0;
SELECT * FROM [home depot employees] WHERE clue > 0;

Right on. :D

Dan Mages
04-25-2004, 4:31 PM
Heh :)

Error in SQL syntax before token 'depot'.

SELECT * FROM home_depot_employees WHERE clue > 0;
SELECT * FROM [home depot employees] WHERE clue > 0;

Right on. :D

Thank you for the correction!!

The newest dumb comment from Home Depot's Tool crib, "Uh... what's a spade bit?"

Dan

Ed Falis
04-26-2004, 8:03 PM
Heh :)

Error in SQL syntax before token 'depot'.

SELECT * FROM home_depot_employees WHERE clue > 0;
SELECT * FROM [home depot employees] WHERE clue > 0;

Right on. :D

And I thought it was COBOL. Well, haven't looked at that kind of stuff in 25+ years.

- Ed

Michael Perata
04-26-2004, 8:17 PM
The only thing more annoying than Dan posting a SQL statement is having Aaron QC it. ;)

Chris Padilla
04-26-2004, 9:16 PM
I don't get it.... :D

Christopher Pine
04-26-2004, 9:27 PM
Get this rumour... The company that makes the power tool line for home depot will not be any longer and home depot has contacted with Ryobi to make there power tools.... OIE... I don't care for ryobi much...And even more I headr that sears will be doing the same thing... Maybe ryobi will be able to make there tool standards down to sear... LOL Just joking..

Todd Burch
04-26-2004, 9:32 PM
You are almost correct guys:

select * from home_depot_employees where (clue > 0 AND brain NOT NULL) ;

Aaron Koehl
04-27-2004, 9:02 AM
Well, almost.

select * from home_depot_employees where (clue > 0 AND brain IS NOT NULL) ;

Can't forget the operator in the conditional. :)

Wes Bischel
04-27-2004, 1:33 PM
Chris,
I guess we had to be there :rolleyes: Of course where that is I'm not too sure.

Wes

Byron Trantham
04-28-2004, 8:49 AM
Gee, guys, I'm envious. At my store, I can't FIND an employee to see if this select statement even applies! :mad: :D

select * from home_depot_employees where (clue > 0 AND brain IS NOT NULL)

Dennis Peacock
04-28-2004, 8:57 AM
Gee, guys, I'm envious. At my store, I can't FIND an employee to see if this select statement even applies! :mad: :D

select * from home_depot_employees where (clue > 0 AND brain IS NOT NULL)

Hey Byron,

You mean like this?

find / -name employee -exec ask question; reply="none"
Tee-Hee!!!!! :p :D

Todd Burch
04-28-2004, 9:08 AM
Well Byron - you would have to further qualify the select statement WHERE clause. Aaron?...

Perhaps something like .... WHERE above_previous_condition AND EXISTS (SELECT COUNT(*) from home_depot_local_store WHERE employee_status NOT IN ("off shift", "on break", "sick", "vacation", "goofing off", "special backroom assignment", "collecting buggies", "racing forklifts", "working return desk", "receiving delivery", "flirting with cashier", NULL)) > 0 ;

(I'm sure this would receive a -104 SQLCODE - invalid syntax... It's been a few years...)

Jim Becker
04-28-2004, 9:14 AM
I see we are now making a collection of programming, DBMS and scripting languages...but the leading question is...does the code change if the color of the store is different?

Byron Trantham
04-28-2004, 12:16 PM
I see we are now making a collection of programming, DBMS and scripting languages...but the leading question is...does the code change if the color of the store is different?

Not in my experience. The only store that had employees that were AVAILABLE and KNOWLEDGEABLE is now permanently closed. :mad: It had been open since 190?. Run out of business by, guess who??

Aaron Koehl
04-28-2004, 1:45 PM
Well Byron - you would have to further qualify the select statement WHERE clause. Aaron?...

Perhaps something like .... WHERE above_previous_condition AND EXISTS (SELECT COUNT(*) from home_depot_local_store WHERE employee_status NOT IN ("off shift", "on break", "sick", "vacation", "goofing off", "special backroom assignment", "collecting buggies", "racing forklifts", "working return desk", "receiving delivery", "flirting with cashier", NULL)) > 0 ;

(I'm sure this would receive a -104 SQLCODE - invalid syntax... It's been a few years...)
Very nice, Todd- where'd you learn SQL? :)

_Aaron_

The rest is FYI for those who are interested in seeing in how to fix this subquery.
-----------------------------------------------
I apologize if this isn't something you want to read, but programming is one of my other great passions.)

We see Todd's good use of a sub-select which answers Byron's question-- the query will only try to find the non-clueless employee if and only if there exists an employee who is not busy with the aforementioned list.

The EXISTS operator returns true if there is a result set, false if nothing is returned. If you SELECT COUNT(*), you will always get a result, even if the COUNT() is 0. Thus, in this case, the entire second part of the WHERE expression is nullified.

So, one way (among others) to fix it is to take out the aggregate function (COUNT()) and replace it with a column identifier (say, employeeID, or *).

-A

Jim Becker
04-28-2004, 2:31 PM
Get this rumour... The company that makes the power tool line for home depot will not be any longer and home depot has contacted with Ryobi to make there power tools.... OIE... I don't care for ryobi much...And even more I headr that sears will be doing the same thing... Maybe ryobi will be able to make there tool standards down to sear... LOL Just joking..
This happened last year and is not new information. But minor adjustments...Ryobi isn't making the tools. The large company that happens to make Ryobi tools and other things is doing the manufacturing. The Ridgid brand is still owned by Emerson, but HD has license to continue using that name on the power tools. Also, the hand power tools are made by a number of manufacturers. Interestingly enough, the Ridgid brand is more well known for things like plumbing tools than woodworking power tools!

Todd Burch
04-28-2004, 4:22 PM
Aaron, when you were 2½ years old, I was learning SQL - April 1984 - one year prior to IBM's DB2 (for the mainframe) becoming generally available for anyone to purchase.

I worked a couple years with DB2 in the IBM Software Support Center, supporting DB2 and other relational products. Then, I got promoted to a "planner" for DB2, then I moved back to the field (Houston) to a "systems engineer" position, supporting DB2 technically, onsite at customer locations.

I left IBM in 1990 to write DB2 utilities software. The first product I authored was called CDB/REXX - and, here's the good part - your employer was one of the first clients to purchase it! Ask around - youll see! (CDB/REXX is an extenstion to the REXX programming language that allows SQL to be imbedded.)

And you all thought I was just a wood hack. HA!

Ed Falis
04-28-2004, 4:25 PM
...And you all thought I was just a wood hack. HA!

I'm starting to see where the precision in your work comes from, Todd.

- Ed, another long-time software guy

Todd Burch
04-28-2004, 4:26 PM
You are right Ed. When coding in assembler, "close" doesn't get it done!

Michael Perata
04-28-2004, 5:12 PM
Todd

REXX and OS/2 - where did they go, where did they go?

Ian Barley
04-28-2004, 5:31 PM
Not in my experience. The only store that had employees that were AVAILABLE and KNOWLEDGEABLE is now permanently closed. :mad: It had been open since 190?. Run out of business by, guess who??

It's customers??

Dan Mages
04-28-2004, 7:46 PM
Not in my experience. The only store that had employees that were AVAILABLE and KNOWLEDGEABLE is now permanently closed. :mad: It had been open since 190?. Run out of business by, guess who??

I know how you feel. My family had a hardware store that opened in 1908. We had to shut it down in 2001 after my uncle lost his battle in cancer. I learned a great deal from that place. I will miss it.

Dan