Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: Filtering on a parameter Post Reply Post New Topic
Author Message
Goldberg
Groupie
Groupie
Avatar

Joined: 15 Apr 2011
Location: Portugal
Online Status: Offline
Posts: 58
Quote Goldberg Replybullet Topic: Filtering on a parameter
     Posted: 27 May 2011 at 1:05am
Hi,

I have a data base called Students with the fields:
idstudent, name, age, status, register_date ...

On CR, I have a parameter with the code {Students.Idstudent} = {?name} that shows me all the names I have.

I'd like to know how can I make it so that it only shows me the students names that on the field "status" have, for example, "1"

Thanks




Edited by Goldberg - 27 May 2011 at 1:10am
IP IP Logged
sharona
Senior Member
Senior Member
Avatar

Joined: 16 Oct 2008
Location: United States
Online Status: Offline
Posts: 255
Quote sharona Replybullet Posted: 27 May 2011 at 3:18am
in the record selection enter
 
(if status =1 then true
and {Students.Idstudent} = {?name})
 
if you want the option to run all the students that have status=1 enter ALL in your parameter and in the record selection enter
(if status =1 then true
and( if {?name}='ALL' then true else {Students.Idstudent} = {?name})
 
sharona
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