decode function(urgent) [message #373770] |
Mon, 07 May 2001 15:36 |
parvind singh
Messages: 2 Registered: May 2001
|
Junior Member |
|
|
select decode(temp,x,y,null) as test1||
decode (temp,z,l,null) as test2||
decode(temp,d,k,null) as test3
from table_name
Once I ran this query, then it return 3 rows.
Is there any way, can I get output in one row only ?
|
|
|
|
Re: decode function(urgent) [message #373781 is a reply to message #373771] |
Tue, 08 May 2001 07:39 |
parvind singh
Messages: 2 Registered: May 2001
|
Junior Member |
|
|
I am using this set of possible in reports. In reports for one column, there is couple of possible value. If there is only one then it reurn only one rows but if there is more than one then it return more than one rows. So in report for that column valued displayed in two rows.
example. xx=00 01 02 00 03.
select decode (xx,0,00)||decode(xx,1,01)... from table
If this sql statment if there is more than one decode cond is true then it will return more than one rows, but I need only one rows in format of xx value.
|
|
|
|
|