databricks/Spark-The-Definitive-Guide

chap3 - streaming write results in console

maelfosso opened this issue · 3 comments

Hi,

I start learning Apache Spark by reading that book. I'm now at chapter 3 - Streaming part.
For snippet code, I choose python3
My problem is that nothing is displayed in console, as said in the book, from that code

purchaseByCustomerPerHour.writeStream \
    .format("console") \
    .queryName("customer_purchases_3") \
    .outputMode("complete") \
    .start() \
    .show() 

I don't know if I'm doing something wrong but tell me how to display result in console at start and at every update too

Are you running this on your laptop/desktop computer ?

@anabranch
I'm running it on my laptop.

Is there anything I forget to install ?

Is it in a notebook of some sort or just in the terminal?

I would recommend running all the code again, you should definitely see it. This has never been reported before and I know a lot of people have run it so it's likely something you're doing. If you can provide more specifics about what you're doing, I can help more but with the information you're providing me I don't have much to go off of.