I have a dataframe with two columns (words, numbers) such that under words I have an array of Strings and numbers I have an array of Integers.
For example:
words: ["hello","there","Everyone"] and numbers: [0,4,5]
I would like to be able to get the words where the integer in numbers is not 0. thus in the above scenario only "there" and "Everyone" should be returned.
I am still a beginner in scala and spark and thus I tried filter, but how could I get inside the array? and how could I return the words ?
like df.filter(col("numbers") != 0)