Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Arrival Date Parameter Post Reply Post New Topic
Author Message
skipwhitten
Newbie
Newbie
Avatar

Joined: 02 Jun 2011
Online Status: Offline
Posts: 3
Quote skipwhitten Replybullet Topic: Arrival Date Parameter
    Posted: 13 Dec 2011 at 5:29am
Hi,
I have a report that includes a date parameter (equal to ot greater than) that won't return data that has a date in next year (2012). I did not create this but the end users tell me that this happens every December and that the previous consultant would tweak it and they'ld be good for the next 12 months. I would appreciate any guidance and I thank you in advance.
 
Skip
Skip Whitten, MCP
IT Consultant
http://www.biocompatibles.com
IP IP Logged
comatt1
Senior Member
Senior Member
Avatar

Joined: 19 May 2011
Online Status: Offline
Posts: 337
Quote comatt1 Replybullet Posted: 13 Dec 2011 at 6:06am
What are you trying to achieve? Could you link the parameter currently being used, and maybe the formula it uses?
 
I can only assume that maybe year is evaluated by "{print date}" or something.
 
If I saw select I could figure it out
IP IP Logged
skipwhitten
Newbie
Newbie
Avatar

Joined: 02 Jun 2011
Online Status: Offline
Posts: 3
Quote skipwhitten Replybullet Posted: 13 Dec 2011 at 6:21am
not ({tsoSalesOrder.Status} in [4]) and
{tsoSalesOrder.CompanyID} = "BIO" and
{tsoSalesOrder.DfltPromDate} >= DateTime (2011, 12, 01, 00, 00, 00) and
{tsoSalesOrder.DfltShipDate} >= DateTime (2011, 12, 01, 00, 00, 00) and
{tsoSalesOrder.Expiration} >= DateTime (2011, 12, 01, 00, 00, 00) and
{@Seed Arrival Date} >= {?Seed Arrival Date}
 
This report lists orders by their arrival date. This data is stored in a udf. The formula to re-arrange the format looks like this (12/13/110
if length ({tsoSalesOrder.userFld1}) = 10
then {tsoSalesOrder.userFld1}[6 to 7]+ "/" + {tsoSalesOrder.userFld1}[9 to 10] + "/" + {tsoSalesOrder.userFld1}[3 to 4]
else {tsoSalesOrder.userFld1}
Skip Whitten, MCP
IT Consultant
http://www.biocompatibles.com
IP IP Logged
comatt1
Senior Member
Senior Member
Avatar

Joined: 19 May 2011
Online Status: Offline
Posts: 337
Quote comatt1 Replybullet Posted: 13 Dec 2011 at 6:45am
are you looking for 12 months of data, or just 2012?
IP IP Logged
skipwhitten
Newbie
Newbie
Avatar

Joined: 02 Jun 2011
Online Status: Offline
Posts: 3
Quote skipwhitten Replybullet Posted: 13 Dec 2011 at 6:51am
They usually look from today forward about two months, max.
 
Thanks,
 
Skip
Skip Whitten, MCP
IT Consultant
http://www.biocompatibles.com
IP IP Logged
comatt1
Senior Member
Senior Member
Avatar

Joined: 19 May 2011
Online Status: Offline
Posts: 337
Quote comatt1 Replybullet Posted: 13 Dec 2011 at 7:04am

use

datetime(DateAdd ("m", 2, CurrentDate)), that should work

{tsoSalesOrder.DfltPromDate} >= DateTime (2011, 12, 01, 00, 00, 00) and
{tsoSalesOrder.DfltShipDate} >= DateTime (2011, 12, 01, 00, 00, 00) and
{tsoSalesOrder.Expiration} >= DateTime (2011, 12, 01, 00, 00, 00)
-----
 
stupid to statically list date years especially in a parameter


Edited by comatt1 - 13 Dec 2011 at 7:05am
IP IP Logged
Post Reply Post New Topic
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



This page was generated in 0.031 seconds.