Why “why” is the right answer. (I’m talking about “why” tonight at IOUG-A, and I wanted to get the gist down and get feedback on the thoughts – please – feedback away!)
I’m into polls all of a sudden – I want to know what people think, about a particular question.
If you ask someone a question and they ask “why” or for clarification/more information – is that rude? Insulting? Unproductive? Presumptuous? Do you think it is insulting to be asked to justify what you are asking to do? Especially in an environment where the people talking to each other don’t necessarily know each other… Like an internet discussion forum.
I’d like to know, if someone asks a question like “how do I ….”, is it insulting to ask ‘why’. I’ll postpone the poll to the bottom – after I say why I think “why” is the right and in many cases the only safe answer…
Let’s say the question is “How do I reorg a table?”. One could answer in many ways:
- Alter table move, followed by index rebuilds
- Create table as select
Among others. Let’s say you don’t ask why and you pick “alter table move” as the answer. Ok, what have you done? I’ll say you just made them schedule downtime, you just made them move a 10 gig table and rebuild all of the indexes.
And why did you do that?
Well, because they had 1,000 chained rows.
And after the rebuild. They still had 1,000 chained rows.
What did they get? Downtime. Did they achieve their goal? No. Why not? We didn’t ask “why”. The right answer for them was not even on the list. When you find you have chained rows, you must first determine “are they chained because they don’t fit on a block” – you won’t fix that with a reorg no matter how many times you do it. If they are migrated – you have to ask yourself “should I reorg the ENTIRE table, or maybe just analyze the table and list the chained rows, select them out, delete them and put them back”. It could be that in seconds you accomplish your goal – without downtime, no downtime.
Or someone asks “How do I create a table in a stored procedure”, you can answer this in one of two ways:
- get CREATE TABLE granted directly to you, then use EXECUTE IMMEDIATE ‘create table ….’
The only correct answer to me is “why”. Why? Because doing DDL in Oracle is really expensive (the tradeoffs you have to make -- make it expensive). Because temporary tables in Oracle works differently than in SQLServer. Because the person asking the question might well have 10 years of experience in databases – just in a different one. I want to know WHY. If the answer is “we are porting stored procedures from SQLServer/Informix/Whatever” my answer is “let me tell you about Oracle”.
If the answer to “why” is “we are creating an install script and need the error handling of a language like PL/SQL” then the answer is #1.
Oh and the list goes on. And on. And on.
So, I’d like to know. If you ask a question on a forum (remember, we don’t know each other, the person asking the question doesn’t necessarily know the person giving the answer and vice versa), would you be insulted by someone asking you “why do you want to do that, what is your goal, what do you hope to achieve”. I’ll let you know my answer – I think it would be entirely unprofessional, naïve, and dangerous not to. That probably messes up the poll, but let’s see what we see. Warning: the poll is a free site, it will show you ads that are wholly unrelated to me and this blog.