Skip to content

Tag: join

Which join or approach to use

I have two tables. First table contains names of individual teams and teamID which is PK. Second table contains details about matches: homeTeamID, awayTeamID, result. I somehow need to combine these two tables in which I would have names (not IDs) of home and away team and the result of a match. How to achiev…

How do I complete a cross join with redshift?

I have two tables. One has a user ID and a date and another has a list of dates. I’m getting this error with redshift Error running query: Specified types or functions (one per INFO message) not supported on Redshift tables. Can I do a cross join with redshift? Answer Alas, Redshift supports generete_se…

Correspondence between two tables

I have table the table code_Commune contains gps for the city in general code_Commune: Now I need to do correspondence with the table lead to add code_commune and Nom_Commune: Table lead Is there any way to do correspondence between the two tables? Answer You can find the closest city using some sort of dista…