Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: help with sort the data Post Reply Post New Topic
Author Message
rp123
Groupie
Groupie


Joined: 26 Feb 2009
Location: United States
Online Status: Offline
Posts: 47
Quote rp123 Replybullet Topic: help with sort the data
     Posted: 16 Mar 2009 at 7:24am
Q. I have a field that is {probsummarym1.severity.code} which is a string type and the data is contains is 1,2,3,4,5..... etc.

{probsummarym1.assignment}
1
2
3
4
5
...

I want sort out the data and list only top 3 severity code  (1,2,3) in the final report.

But the problem is that when the final report comes it just print true or false.

So can you guys help in this. I think first we need the filed to convert from string to numeric and then sort it and list severity code 1,2,3 only in the final report.
rp
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 Mar 2009 at 7:40am

Not sure what is happening with the true / false printing...

If you want to exclude anything that is not = 1, 2 or 3 in that field from the report altogether then in your select statement use:
{probsummarym1.assignment}  in ["1", "2", "3"]
 
If you want to convert it to an int then use a formula field:
tonumber({probsummarym1.assignment})


Edited by DBlank - 16 Mar 2009 at 7:40am
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum