I have a pandas data frame with really long text in a column. I wanted to select all columns that contain ABC. I was able to do this using the following
df[df['Column'].str.contains('ABC', na=False)]
What I want to do after that is extract all values from this field that contain the prefix and the next 5 letters. S.So after finding a column, I would want to get ABC1234 or ABC7899.
I hope this makes sense.