Q: Select a range of columns in Spark Dataframe Assuming that I have a Spark Dataframe df, how can I select a range of columns e.g. from column 100 to column 200? 

A: Since df.columns returns a list, you can slice it and pass it to select:
df.select(df.columns[99:200])

This gets the subset of the DataFrame containing the 100th to 200th columns, inclusive.
