dsp
dsp

Reputation: 171

deal with datetime

Im new using python. I have a dataframe with 3 columns (id, beg, end) what to search clients that was connected to our website on the 2021-09-09 like shown in the expected ouput below. the only data that i have is clients disconnected from beg date to end date.

My initial dataframe.

id  beg                      end                    
x1  2021-09-08 10:00:00      2021-09-10 10:00:00                
x2  2021-09-09 22:00:00      2021-09-10 00:00:00    
x3  2021-09-08 10:00:00      2021-09-09 10:00:00    
x4  2021-09-09 10:00:00      2021-09-09 14:00:00

Upvotes: 1

Views: 58

Answers (1)

gbajson
gbajson

Reputation: 1730

You might use excellent library to deal with date formats: https://dateparser.readthedocs.io/en/latest/

Upvotes: 1

Related Questions