User Profile

Collapse

Profile Sidebar

Collapse
Rantoun
Rantoun
Last Activity: Sep 21 '10, 08:55 AM
Joined: Oct 29 '08
Location: Lebanon
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Rantoun
    replied to Group consecutive records
    Ok got an answer for this one... here is it for those of you who come across this post...

    Code:
    select to_char(min(deviceDate), 'hh24:mi:ss'), community from 
    (
    	select devicedate, community,
    	       max(rn) 
    	         over(order by devicedate) max_rn
    	  from (
    		select devicedate, community,
    		       case
    		       when not (COMMUNITY = LCOMMUNITY) or lcommunity is null
    ...
    See more | Go to post

    Leave a comment:


  • Rantoun
    started a topic Group consecutive records

    Group consecutive records

    I know what I am asking for is pretty hard, but still maybe there is someone out there who is able to solve my problem!

    I have a table that look like this
    CREATE TABLE VEHICLETRIPS
    ( VID NUMBER(10) NOT NULL,
    VECHIELID VARCHAR2(10) NOT NULL,
    DEVICEDATE DATE NOT NULL,
    TRIPID NUMBER(10) NOT NULL,
    COMMUNITY VARCHAR2(10) NOT NULL
    ) ;


    INSERT INTO
    ...
    See more | Go to post
No activity results to display
Show More
Working...