I have a database of supermarket transactions that I wish to use for associative data mining purposes. Below is an image of my current SQL query however I am not sure if what I require is possible with SQL (Explained below image).
I need my results to be in the following format – Each unique ProductName needs to have its own column with a binary 0/1 representation of whether the CustomerID purchased the product.
Is this possible? If so where exactly would I start?