The Question of the day...
Some days... Some days the questions just make me scratch my head....
ROW TO COLUMN CONVERSION April 30, 2008 - 5am US/Eastern
Reviewer: ROOPA from indiaHOW TO CONVERT YEARLY DATA INTO MONTHLY DATA?
Followup April 30, 2008 - 10am US/Eastern:
BY MAKING IT UP I GUESS?
Could it be more ambiguous? I have yearly data (one presumes that is data aggregated to the level of a year). How do I convert that into monthly data. Short of "making it up", I have no idea... do you?
Now, they did followup later with
table1 format
MONTH AMOUNT_PAID
01.12.2006 00:00:00 5395
01.11.2006 00:00:00 567
01.11.2006 00:00:00 1974
01.04.2007 00:00:00 2462
01.04.2007 00:00:00 1974
01.11.2006 00:00:00 5395
01.02.2008 00:00:00 5395
table2 format
MONTH JAN FEB MAR APR MAY JUN JUL AUG SEP OCT NOV DEC
01-DEC-2006 0 0 0 0 0 0 0 0 0 0 0 5395
01-FEB-2007 0 5395 0 0 0 0 0 0 0 0 0 0
01-NOV-2006 0 0 0 0 0 0 0 0 0 0 5395 0
how to convert table1 format into table2 format i.e yearly data to monthly data.
Now, I don't know about you - but table1 looks suspiciously like "discrete observations with an associated date - the date consisting of year, month and day". I certainly do not see "yearly data".
I also like how they used 5,395 three times, just to make it as ambiguous as possible (wonder what happened to 567, 1,974 and so on?) They skipped what are likely the interesting output examples - their "yearly data that is not yearly" that has more than one observation in a month.
I guess, I GUESS, their date format is DAY-MONTH-YEAR now, that changes table1 to look suspiciously like "discrete observations with an associate date - the date consisting solely of year and month". But, we'd be GUESSSING.
And I see a 01-FEB-2007 in table2, but I see 01.02.2008 in table1. I have to presume that is a "typo"
sigh, and there wasn't even a create table, insert into table supplied - they want me to do that.
And the output looks utterly useless. If column 1 is "01-dec-2006", why bother having a DEC column in the output? We already KNOW what month this is for - every row will have 11 zeros, every single one. Seems a bit "silly".
Asking good, well formed questions is not an art, not magic. It is however a skill. And I find many times that when I frame my question for someone else - I find my answer.
Goes back to yesterdays post. Writing software requires some things - a plan being one of them. Until you can phrase your requirements in a detailed fashion - I'm not sure you know what they are or why you are doing something.....
We have a runner up for second place..
entire question is:
Record level Audit Old\New value same Error April 30, 2008 - 9am US/Eastern
Reviewer: sasirekha from India
I have some problem using Audit Record.
Generally if we map a record to the audit Record, it will track the details of
the table insert, update, delete.
While I update the record, it will insert two different row in audit record
like Audit Action K and N.
But both are contain the same values..
I need the old and new value.
Can any one please give me the solution with this !
questions from me:
- what is an "audit record", must be well defined - they are using it
- "if we map a record to the audit record" - not really sure what that means
- "like audit action K and N" - K and N?? huh?
- "but both are contain the same values - I need the old and new value" - well, why didn't they access the old and new values?
- where is the sample, the example, the thing that shows us what you are really doing....
And in a close 3rd place...
How to speed up the insert and update in a partion table of more than 60 millions Rows ?
Best regards,
Sam.
I don't get it some days, just do not get it.


