Forum Discussion

maico_presente's avatar
maico_presente
Regular Visitor
6 years ago
Solved

Date Value from previous record

Hello,

 

I've been working on a problem for hours and can't get any further! HELP ;-))

 

I have a list of users who belong to a group from a certain date.
If a user is moved to another group i have another entry with the new "from" date.

I need a new column (date_to) that says until when the user was in the group. If there is no newer entry the date of today should be entered.

 

user_numbergroup_iddate_from
123xy10.11.2015
123ab05.07.2017
123de26.09.2019
456xy05.12.2016
456de03.03.2019

 

expected result:

user_numbergroup_iddate_fromdate_to
123xy10.11.201504.07.2017
123ab05.07.201725.09.2019
123de26.09.201912.12.2019
456xy05.12.201602.03.2019
456de03.03.201912.12.2019

3 Replies