Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

distinct between positive & negative numbers of a single column 1

Status
Not open for further replies.

chochoo

Programmer
Aug 24, 2003
33
0
0
PK
hi
i want to know how to distinct between postive and negative number of a summary based column in reports at run time.
i want to put positive numbers in seperate column and negative in seperate.
thanx in advance
 
You may use decode() in your base query:

select
...
decode(sign(col),1,col,null) pos,
decode(sign(col),-1,col,null) neg,
...

You mayalso print them in the same column but with differnt colors/styles by using format triggers.

Regards, Dima
 
thanx sem! Now i've solved my problem :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top