edf.select(\"x\").distinct.show() shows the distinct values that are present in x column of edf DataFrame.
edf.select(\"x\").distinct.show()
x
edf
Is there an efficient
df.select("some_column").distinct.count