[askdba] Re: Query format - Urgent

  • From: Ganesh Raja <ganesh.raja@xxxxxxxxx>
  • To: askdba@xxxxxxxxxxxxx
  • Date: Mon, 11 Oct 2004 11:05:58 +0100

Pradhan,

If your Rows are static Use Decode If not u need to Use a Reporting tool.

Cheers
Ganesh


On Mon, 11 Oct 2004 11:12:29 +0530, Pradhan <pradhan@xxxxxxxxxxxxxxxx> wrote:
> Hi Folks,
> I have a query which gives me data in vertical format eg:
> 
> select empnum, saldesc, amount1, amount2 from salinfo
> 
> empnum    saldesc    amount1    amount2
> --------    -------    -------    ---------
> 001          basic        100.00        0.00
> 001          splall         132.00      50.00
> 001          da            200.00       10.00
> 001          inctax       50.00          0.00
> 
> I want the same to be formatted as
> 
> empnum   basicamt1   basicamt2   splallamt1    splallamt2    daamt1    daamt2 
>    inctaxamt1    inctaxamt2
> --------  ----------    --------    ---------    ----------    -------    
> ------    -----------    ----------
> 001         100.00       0.00            132.00        50.00        200.00    
>   10.00      50.00            0.00
> 
> can any one help me in getting the data in the above said format.
> 
> Warm Regards,
> 
> Pradhan
> 
>

Other related posts: