how to find latest time point from same day

Accepted Solution Solved
Reply
Occasional Contributor
Posts: 7
Accepted Solution

how to find latest time point from same day

Hi _ALL_

This is vicky i am having difficulty in finding latest TIME point from same DATE from below data  , some one  help me.

DATETIMEDEPTH
10/7/201310:25:414781.35
10/9/201316:45:290
10/9/201317:28:310
10/13/20138:54:2275.18197
10/13/201314:03:2787.27948
10/13/201320:46:52115.8728
10/14/20133:18:32135.7762
10/14/20137:38:21153.6802
10/14/201314:44:03181.4292
10/14/201318:57:05209.2909
10/15/20131:13:23237.2716
10/15/20135:26:44265.3894
10/15/20137:57:18274.509
10/15/201312:29:55303.2821
10/15/201316:57:01331.976
10/14/201320:02:00109.1032
10/16/20135:17:51385.9804
10/16/20135:58:19397.7579
10/16/20132:10:00360.8314
10/26/201316:42:01390.7048
10/26/201321:57:56419.0634
10/27/20132:21:01447.8823
10/27/20137:38:20476.3902
10/27/201312:48:38504.8128
10/27/201317:31:18532.0619
10/27/201322:11:26560.8838
10/28/20133:59:01588.7486
10/28/201310:34:02616.647
10/28/201318:17:32643.2316

Accepted Solutions
Solution
‎12-05-2014 09:21 AM
Respected Advisor
Posts: 3,156

Re: how to find latest time point from same day

Here is a possible SQL solution:

PROC SQL;

  CREATE TABLE WANT AS

  SELECT * FROM HAVE

   GROUP BY DATE

   HAVING TIME=MAX(TIME)

;

QUIT;

Haikuo

View solution in original post


All Replies
Solution
‎12-05-2014 09:21 AM
Respected Advisor
Posts: 3,156

Re: how to find latest time point from same day

Here is a possible SQL solution:

PROC SQL;

  CREATE TABLE WANT AS

  SELECT * FROM HAVE

   GROUP BY DATE

   HAVING TIME=MAX(TIME)

;

QUIT;

Haikuo

Occasional Contributor
Posts: 7

Re: how to find latest time point from same day

HI Haikuo

THANKS FOR YOUR REPLY ITS WORKING.

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

Discussion stats
  • 2 replies
  • 253 views
  • 0 likes
  • 2 in conversation