[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Crystal Report Is Not Sorting DateTime field

Posted on 2005-05-08
11
Medium Priority
?
1,511 Views
Last Modified: 2008-02-01
I am trying to get this Crystal report to sort the DateTime field correctly but it can't seem to sort the time right. The report is grouping by two fields, then the starttime, which when I browse it says it is a type DateTime.  The sort order is the same as the grouing order, and it's grouping correctly, However I am always getting this order:
May 06, 2005 1:22:22 pm
May 07, 2005  1:32:29 pm
May 07, 2005 12:49:20 pm
May 07, 2005  1:12:20 pm
May 07, 2005 12:18:59 pm

I even tried changing the order by clause in the stored procedure of the data source, which didn't help, not that I really thought it would but I'm desperate.
0
Comment
Question by:cab_codespring
9 Comments
 
LVL 9

Expert Comment

by:cyberdevil67
ID: 13957335
Hi cab_codespring,

 have you selected this field and added it to the sort order?

Cheers!
0
 

Author Comment

by:cab_codespring
ID: 13957355
Yes I did, well when I changed the group order it automatically changed the sort order.
I'm doing this in VS.NEt btw. When I right click on the details section and choose  report/sort records it brings up the Record Sort Order window that shows the sort order, and it's right where it should be.
0
 
LVL 5

Expert Comment

by:SaxonWica
ID: 13957380
You said that :

"The report is grouping by two fields, then the starttime, which when I browse it says it is a type DateTime"

What's the first two fields? And where did you put the starttime that shows incorrect sort order?
0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 6

Expert Comment

by:cjard
ID: 13957993
these datetimes are all in the same time zone arent they?
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 13959113
What are the other groups?

Is there anything in the other group headers?   If not put the group name in them.  You may be seeing the other groups affect your sorting.  

mlmcc
0
 

Author Comment

by:cab_codespring
ID: 13962414
<<<You said that :

"The report is grouping by two fields, then the starttime, which when I browse it says it is a type DateTime"

What's the first two fields? And where did you put the starttime that shows incorrect sort order?>>>
 The heirarchy of this data is:
 Jails: Jail 1, Jail 2 etc.
      HU: Housing Units (Cell blocks) HU-1, HU-2 etc.            
           location:  (Cells) which is on the detail line, which has a corresponding  start time, (which is copied, because I use the identical field to display only the date, and then the starttime which shows the time is the same field.)


The GROUPING in the report is:
Jail Name
   HU Name
      StartTime
        LOcationName
           end time
             tour id

The Sorting is identical:
Jail Name
   HU Name
      StartTime
        LOcationName
           end time
               tour id

The report can be seen here:
     http://meadow.no-ip.com/images/report.jpg

<A HREF="http://meadow.no-ip.com/images/report.jpg">is this how you do links here?</A>



0
 

Author Comment

by:cab_codespring
ID: 13962444
Time zone?  The dates coming into the report are the ones I showed in the original post. A normal SQL DateTime..
0
 

Author Comment

by:cab_codespring
ID: 13963364
I know the problem, somebody else helped me. I needed to have iot sort the starttime by second, and not by week!!! I had to go to the Report/ChangeGroup Expert/options button and select the starttime and bel,ow set it to go by seconds. problem solved. So thanks everyone, this is my first question I have no idea how it works if I solve it myself.
0
 
LVL 1

Accepted Solution

by:
GhostMod earned 0 total points
ID: 14000495
PAQd, 500 points refunded.

GhostMod
Community Support Moderator
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…
Is your OST file inaccessible, Need to transfer OST file from one computer to another? Want to convert OST file to PST? If the answer to any of the above question is yes, then look no further. With the help of Stellar OST to PST Converter, you can e…
Suggested Courses

873 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question