Home > Enterprise >  How to get the last/maximum date that is on/earlier than another baseline date by user?
How to get the last/maximum date that is on/earlier than another baseline date by user?

Time:08-17

I have a df where I am trying to create the Last Login Date column, as shown in the image.

I am not sure how to get the maximum login date that was on/prior the email notification date for that current row. I added explanations on how I expect the data to look. Any help is appreciated in either sql or pandas.

enter image description here

CodePudding user response:

Use enter image description here

  • Related