Documentation

Change Join Type

When building a chart with data from two or more tables you might need to change the Join Type between your tables to get the desired results. Before you start combining datasets from various tables, you should make sure that you have connected the tables in the settings section by defining foreign key relations between them. Click here for more information on how to join your tables in datapine.

 

Please follow the instructions below to define the correct join type for your query.

 

1) Build your chart by dragging and dropping the fields from the left into the visualization area on the right.

 

2) Click on Change Join Type at the bottom of the Measures & Dimensions.

 

3) This will open the Query Options on the right side of your screen. There you can choose from three different Join Types to customize your resulting data set.

 

a) Inner Join: The Inner Join matches the set of records that appear in both, the Y- and X-Axis. Values from the field in your dimension (X-Axis) which have no corresponding value in the measured field (Y-Axis) will not be shown.

 

b) Left Join: The Left Join will return all values of the field in your dimension (X-Axis) and the corresponding values in the Y-Axis. If there are no corresponding records in the measured field, they will be shown as NULL.

 

c) Right Join: The Right Join returns all values from the field in your Y-Axis and the corresponding dimensions (X-Axis). If there are no corresponding records in the dimension, they will be shown as NULL values.

 

4) Click on the join type that you wish to apply to your chart and then hit the Apply button.

 

Tip: For a more detailed explanation of the different join types visit our datapine blog.