sort dataframe y column code example Example: python dataframe sort by column name >>> result = df.sort(['A', 'B'], ascending=[1, 0])