Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: Simplifying Record Selection Coding Post Reply Post New Topic
Author Message
Csukardi151
Newbie
Newbie


Joined: 02 Feb 2009
Location: United States
Online Status: Offline
Posts: 8
Quote Csukardi151 Replybullet Topic: Simplifying Record Selection Coding
     Posted: 07 Jun 2012 at 4:21am
I'm trying to have simple coding in the record selection field. However the way i'm going about it (probably the wrong way) doesn't work out the way I was hoping.

I was trying to create a code that looked just like this:
{date} in {?startdate} to {?enddate} and
{account} = ("200"; "300"; "400")

That didn't work, account 200 would not be listed in the report when it should be. The formula below DOES work:
{date} in {?startdate} to {?enddate} and
{account} = "200" or
{date} in {?startdate} to {?enddate} and
{account} = "300" or
{date} in {?startdate} to {?enddate} and
{account} = 400"

Could someone please inform me of the proper way to write what i'm trying to achieve? I would not like to mess up a report with bandaids just to see it work. Thank you!
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 07 Jun 2012 at 4:27am
{date} in {?startdate} to {?enddate} and
{account} in ["200","300","400"]
IP IP Logged
Csukardi151
Newbie
Newbie


Joined: 02 Feb 2009
Location: United States
Online Status: Offline
Posts: 8
Quote Csukardi151 Replybullet Posted: 07 Jun 2012 at 4:32am
So I was just off by a simple character mistake? Haha, not bad, at least I was close. Thank you for the quick response.

I will be trying this now.

Edit: 2 simple character mistakes ;)

Thank you again, it worked perfectly.

Edited by Csukardi151 - 07 Jun 2012 at 4:39am
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