create empty spark df with schema code example Example: how to create empty data frame in scala val df = spark.emptyDataFrame