Databricks Sql Partition By Condition