Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sorting Group by Ascending Time

Status
Not open for further replies.

Jwalker62

Technical User
Mar 11, 2015
3
US
I'm a new Crystal Reports user and trying to create a report for school bus routes that is grouped by bus number, then bus route start time,and sorted in ascending order.

The report looks like this:

Group 1: Bus ID
Group 2: Route Start Time
Group 3: Bus Stops

Everything sorts and groups perfectly except that Group 2 is not recognizing AM and PM.

Example: Bus 17's routes are being ordered 2:40pm, 3:25pm, 6:04am, 6:40am, 7:55am when it should be 6:04am, 6:40am, 7:55am, 2:40pm, 3:25pm.

Any help will be greatly appreciated!
 
Time IS Date/Time!

Your "time" field is sorting like a STRING field not a Date/Time field!
 
What I'm saying is the type options are boolean, currency, date, date time, number, string, and time.

It is set as time, not string.
 
If it is a Time field, you ought to be able to change the FORMAT between Military & AM/PM. Can you do this?
 
Here's an easy test:
create a formula that is TIME({your_time_field})
If you get an error, then it is an actual time already
If you do not get an error, then it is a text file and you can sort on the formula you just created.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top