Hacker News new | ask | show | jobs
by all2 2618 days ago
I thought a cartesian (cross) product produced an ordered output (tuple), an element from each set?

I don't have any experience with data science, but my brain wants to apply linear algebra and set theory...

So, in the above linked example, to clean we would first do an intersect operation on user names to remove people who don't appear in each set.

Then, to put the tables together (to append emails to appropriate names) we do a cross product between the filtered sets (assuming the sets have been ordered).

Is my intuition correct? I also have zero experience with DBs.