How to Change text to date in SelectionFormula in CrystalReport3.0 
Author Message
 How to Change text to date in SelectionFormula in CrystalReport3.0

I'm trying to use Crystal Report 3.0 to produce a list of records, where
the DATE field is in a specific range of date. I'm using Access 97 as my
database and here, the DATE field is stored as TEXT.

How can i format the date ( In VB I can use format(date, "yyyy,mm,dd") )
in the SelectionFormula ( where date "in Date(1999,01,01) to
Date(1999,06,30)" for example)?



Tue, 01 Jan 2002 03:00:00 GMT  
 How to Change text to date in SelectionFormula in CrystalReport3.0

Quote:

> I'm trying to use Crystal Report 3.0 to produce a list of records,
> where the DATE field is in a specific range of date. I'm using Access
> 97 as my database and here, the DATE field is stored as TEXT.

> How can i format the date ( In VB I can use format(date, "yyyy,mm,dd")
> ) in the SelectionFormula ( where date "in Date(1999,01,01) to
> Date(1999,06,30)" for example)?

  If it's a text type field, how are the dates actually typed in?  Like
07/16/99, or like 17 July, '99?  ...or what?
  If it's conventional style like 07/16/99, you're in luck.  You can use
a where clause to return all records with dates in July:
  WHERE (Date > "07" AND Date < "08")
But if a July date was put in as 7/16/99, it won't be found.  So, I hope
the data entry was consistent.  
  Another problem with dates as text...if they didn't use two-digit
months (01, 02...), then if you ask for all dates > "1" and < "3", you
won't just get Jan and Feb, you'll also get months 10, 11, and 12.
  Good luck!
--
Jim in Cleveland
If you're writing to me, in my address
change "REAL_Address.see.below" to "worldnet.att.net"

"What's so funny 'bout peace, love & understanding?"
     - Nick Lowe



Tue, 01 Jan 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. VB and Crystal Report : Selectionformula with date

2. SelectionFormula and Date variable

3. VB and Crystal Report : Selectionformula with date

4. Crystal Reports - Report1.SelectionFormula{Date} ??

5. Help: Date/Time in SelectionFormula

6. SelectionFormula and dates

7. Help on Date compare in Selectionformula

8. Comparing Dates using SelectionFormula

9. HOW TO : Assign Date Value to SelectionFormula

10. SelectionFormula with Dates

11. SelectionFormula for Date/Time fields

12. HELP to CHANGE selectionformula runtime!!!

 

 
Powered by phpBB® Forum Software