Advertisement
g96

Untitled

g96
Mar 21st, 2022
153
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.47 KB | None | 0 0
  1. for filename in os.listdir(path):
  2.     if filename.startswith("PB orders"):
  3.         full_path = os.path.join(path, filename)
  4.         month = pd.read_excel(full_path, sheet_name="Raw data ", engine="pyxlsb")
  5.         month = month[month['Sales Manager'] == 'MCLEAN, COLM']
  6.         month=month.drop(month.columns[[10]], axis=1)
  7.         filename, extension = os.path.splitext(filename)
  8.         line = filename + '.csv'
  9.         month.to_csv (path + line, index = None, header=True)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement