Task: equi-join-detect (source dataset: Auto-BI)

Your are given a database with related tables used for business intelligence analysis. Your task is to identify all key/foreign-key join relationships between the tables for this database. Recall that a join is a relationship between two tables, that allows rows from one table to be combined with rows from another, based on a set of common join columns.
 
 
No explanation needed. Please return all join relationships in the following JSON format:
{
  "joins": [
    {
      "from_table": "table-1",
      "from_column": "column-1",
      "to_table": "table-2",
      "to_column": "column-3"
    }, 
	...
  ]
}

Tables:

Table: categorias
| Product                   |
|:--------------------------|
| HL Road Frame - Black, 58 |
| HL Road Frame - Red, 58   |
| HL Road Frame - Red, 62   |
| HL Road Frame - Red, 62   |
| HL Road Frame - Red, 62   |
| HL Road Frame - Red, 44   |
| HL Road Frame - Red, 44   |
| HL Road Frame - Red, 44   |
| HL Road Frame - Red, 48   |
| HL Road Frame - Red, 48   |


Table: dCalendario 1
| Date                    |   Ano |   Mês | Nome do Mês   |   Dia |   Trimestre |
|:------------------------|------:|------:|:--------------|------:|------------:|
| 2017-07-01 00:00:00.000 |  2017 |     7 | julho         |     1 |           3 |
| 2017-07-02 00:00:00.000 |  2017 |     7 | julho         |     2 |           3 |
| 2017-07-03 00:00:00.000 |  2017 |     7 | julho         |     3 |           3 |
| 2017-07-04 00:00:00.000 |  2017 |     7 | julho         |     4 |           3 |
| 2017-07-05 00:00:00.000 |  2017 |     7 | julho         |     5 |           3 |
| 2017-07-06 00:00:00.000 |  2017 |     7 | julho         |     6 |           3 |
| 2017-07-07 00:00:00.000 |  2017 |     7 | julho         |     7 |           3 |
| 2017-07-08 00:00:00.000 |  2017 |     7 | julho         |     8 |           3 |
| 2017-07-09 00:00:00.000 |  2017 |     7 | julho         |     9 |           3 |
| 2017-07-10 00:00:00.000 |  2017 |     7 | julho         |    10 |           3 |


Table: DimAcessorios
|   ProductKey | SKU       | Product                 |   Standard Cost | Color   |   List Price | Model            | Subcategory   | Category    |
|-------------:|:----------|:------------------------|----------------:|:--------|-------------:|:-----------------|:--------------|:------------|
|          212 | HL-U509-R | Sport-100 Helmet, Red   |         12.0278 | Red     |      33.6442 | Sport-100        | Helmets       | Accessories |
|          213 | HL-U509-R | Sport-100 Helmet, Red   |         13.8782 | Red     |      33.6442 | Sport-100        | Helmets       | Accessories |
|          214 | HL-U509-R | Sport-100 Helmet, Red   |         13.0863 | Red     |      34.99   | Sport-100        | Helmets       | Accessories |
|          215 | HL-U509   | Sport-100 Helmet, Black |         12.0278 | Black   |      33.6442 | Sport-100        | Helmets       | Accessories |
|          216 | HL-U509   | Sport-100 Helmet, Black |         13.8782 | Black   |      33.6442 | Sport-100        | Helmets       | Accessories |
|          217 | HL-U509   | Sport-100 Helmet, Black |         13.0863 | Black   |      34.99   | Sport-100        | Helmets       | Accessories |
|          220 | HL-U509-B | Sport-100 Helmet, Blue  |         12.0278 | Blue    |      33.6442 | Sport-100        | Helmets       | Accessories |
|          221 | HL-U509-B | Sport-100 Helmet, Blue  |         13.8782 | Blue    |      33.6442 | Sport-100        | Helmets       | Accessories |
|          222 | HL-U509-B | Sport-100 Helmet, Blue  |         13.0863 | Blue    |      34.99   | Sport-100        | Helmets       | Accessories |
|          446 | PA-T100   | Touring-Panniers, Large |         51.5625 | Grey    |     125      | Touring-Panniers | Panniers      | Accessories |


Table: DimBikes
|   ProductKey | SKU        | Product          |   Standard Cost | Color   |   List Price | Model    | Subcategory   | Category   |
|-------------:|:-----------|:-----------------|----------------:|:--------|-------------:|:---------|:--------------|:-----------|
|          310 | BK-R93R-62 | Road-150 Red, 62 |        2171.29  | Red     |      3578.27 | Road-150 | Road Bikes    | Bikes      |
|          311 | BK-R93R-44 | Road-150 Red, 44 |        2171.29  | Red     |      3578.27 | Road-150 | Road Bikes    | Bikes      |
|          312 | BK-R93R-48 | Road-150 Red, 48 |        2171.29  | Red     |      3578.27 | Road-150 | Road Bikes    | Bikes      |
|          313 | BK-R93R-52 | Road-150 Red, 52 |        2171.29  | Red     |      3578.27 | Road-150 | Road Bikes    | Bikes      |
|          314 | BK-R93R-56 | Road-150 Red, 56 |        2171.29  | Red     |      3578.27 | Road-150 | Road Bikes    | Bikes      |
|          315 | BK-R68R-58 | Road-450 Red, 58 |         884.708 | Red     |      1457.99 | Road-450 | Road Bikes    | Bikes      |
|          316 | BK-R68R-60 | Road-450 Red, 60 |         884.708 | Red     |      1457.99 | Road-450 | Road Bikes    | Bikes      |
|          317 | BK-R68R-44 | Road-450 Red, 44 |         884.708 | Red     |      1457.99 | Road-450 | Road Bikes    | Bikes      |
|          318 | BK-R68R-48 | Road-450 Red, 48 |         884.708 | Red     |      1457.99 | Road-450 | Road Bikes    | Bikes      |
|          319 | BK-R68R-52 | Road-450 Red, 52 |         884.708 | Red     |      1457.99 | Road-450 | Road Bikes    | Bikes      |


Table: DimCliente
|   CustomerKey | Customer ID   | Customer          | City    | State-Province   | Country-Region   |   Postal Code |
|--------------:|:--------------|:------------------|:--------|:-----------------|:-----------------|--------------:|
|         11024 | AW00011024    | Russell Xie       | Concord | California       | United States    |         94519 |
|         11081 | AW00011081    | Savannah Baker    | Concord | California       | United States    |         94519 |
|         11160 | AW00011160    | Maurice Tang      | Concord | California       | United States    |         94519 |
|         11161 | AW00011161    | Emily Wood        | Concord | California       | United States    |         94519 |
|         11184 | AW00011184    | Meghan Hernandez  | Concord | California       | United States    |         94519 |
|         11295 | AW00011295    | Taylor Lewis      | Concord | California       | United States    |         94519 |
|         11329 | AW00011329    | Andy Alvarez      | Concord | California       | United States    |         94519 |
|         11499 | AW00011499    | Pedro Vance       | Concord | California       | United States    |         94519 |
|         11539 | AW00011539    | Justin Washington | Concord | California       | United States    |         94519 |
|         11655 | AW00011655    | Tamara Sharma     | Concord | California       | United States    |         94519 |


Table: DimComponente
|   ProductKey | SKU        | Product                   |   Standard Cost | Color   |   List Price | Model         | Subcategory   | Category   |
|-------------:|:-----------|:--------------------------|----------------:|:--------|-------------:|:--------------|:--------------|:-----------|
|          210 | FR-R92B-58 | HL Road Frame - Black, 58 |         868.634 | Black   |      1431.5  | HL Road Frame | Road Frames   | Components |
|          211 | FR-R92R-58 | HL Road Frame - Red, 58   |         868.634 | Red     |      1431.5  | HL Road Frame | Road Frames   | Components |
|          238 | FR-R92R-62 | HL Road Frame - Red, 62   |         747.968 | Red     |      1263.46 | HL Road Frame | Road Frames   | Components |
|          239 | FR-R92R-62 | HL Road Frame - Red, 62   |         722.257 | Red     |      1301.36 | HL Road Frame | Road Frames   | Components |
|          240 | FR-R92R-62 | HL Road Frame - Red, 62   |         868.634 | Red     |      1431.5  | HL Road Frame | Road Frames   | Components |
|          241 | FR-R92R-44 | HL Road Frame - Red, 44   |         747.968 | Red     |      1263.46 | HL Road Frame | Road Frames   | Components |
|          242 | FR-R92R-44 | HL Road Frame - Red, 44   |         722.257 | Red     |      1301.36 | HL Road Frame | Road Frames   | Components |
|          243 | FR-R92R-44 | HL Road Frame - Red, 44   |         868.634 | Red     |      1431.5  | HL Road Frame | Road Frames   | Components |
|          244 | FR-R92R-48 | HL Road Frame - Red, 48   |         747.968 | Red     |      1263.46 | HL Road Frame | Road Frames   | Components |
|          245 | FR-R92R-48 | HL Road Frame - Red, 48   |         722.257 | Red     |      1301.36 | HL Road Frame | Road Frames   | Components |


Table: DimData
|   DateKey | Date                    | Fiscal Year   | Month                   | Full Date               |   MonthKey |
|----------:|:------------------------|:--------------|:------------------------|:------------------------|-----------:|
|  20190701 | 2019-07-01 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-01 00:00:00.000 |     201907 |
|  20190702 | 2019-07-02 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-02 00:00:00.000 |     201907 |
|  20190703 | 2019-07-03 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-03 00:00:00.000 |     201907 |
|  20190704 | 2019-07-04 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-04 00:00:00.000 |     201907 |
|  20190705 | 2019-07-05 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-05 00:00:00.000 |     201907 |
|  20190706 | 2019-07-06 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-06 00:00:00.000 |     201907 |
|  20190707 | 2019-07-07 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-07 00:00:00.000 |     201907 |
|  20190708 | 2019-07-08 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-08 00:00:00.000 |     201907 |
|  20190709 | 2019-07-09 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-09 00:00:00.000 |     201907 |
|  20190710 | 2019-07-10 00:00:00.000 | FY2020        | 2019-07-01 00:00:00.000 | 2019-07-10 00:00:00.000 |     201907 |


Table: DimRegiao
|   SalesTerritoryKey | Region         | Country        |
|--------------------:|:---------------|:---------------|
|                   1 | Northwest      | United States  |
|                   2 | Northeast      | United States  |
|                   3 | Central        | United States  |
|                   4 | Southwest      | United States  |
|                   5 | Southeast      | United States  |
|                   6 | Canada         | Canada         |
|                   7 | France         | France         |
|                   8 | Germany        | Germany        |
|                   9 | Australia      | Australia      |
|                  10 | United Kingdom | United Kingdom |


Table: Sales Amount
|   SalesOrderLineKey |   ResellerKey |   CustomerKey |   ProductKey |   OrderDateKey |   DueDateKey |   ShipDateKey |   SalesTerritoryKey |   Order Quantity | Unit Price   | Extended Amount   |   Unit Price Discount Pct | Product Standard Cost   | Total Product Cost   |   Sales Amount |   Order Quantity - Copiar | pedido                  | entrega                 |   Subtração |
|--------------------:|--------------:|--------------:|-------------:|---------------:|-------------:|--------------:|--------------------:|-----------------:|:-------------|:------------------|--------------------------:|:------------------------|:---------------------|---------------:|--------------------------:|:------------------------|:------------------------|------------:|
|            43663001 |           510 |            -1 |          322 |       20170707 |     20170717 |      20170714 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-07 00:00:00.000 | 2017-07-14 00:00:00.000 |           7 |
|            43666001 |           511 |            -1 |          330 |       20170709 |     20170719 |      20170716 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-09 00:00:00.000 | 2017-07-16 00:00:00.000 |           7 |
|            43666006 |           511 |            -1 |          334 |       20170709 |     20170719 |      20170716 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-09 00:00:00.000 | 2017-07-16 00:00:00.000 |           7 |
|            43678001 |           203 |            -1 |          322 |       20170718 |     20170728 |      20170725 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-18 00:00:00.000 | 2017-07-25 00:00:00.000 |           7 |
|            43678003 |           203 |            -1 |          332 |       20170718 |     20170728 |      20170725 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-18 00:00:00.000 | 2017-07-25 00:00:00.000 |           7 |
|            43678013 |           203 |            -1 |          342 |       20170718 |     20170728 |      20170725 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-18 00:00:00.000 | 2017-07-25 00:00:00.000 |           7 |
|            43680010 |           491 |            -1 |          324 |       20170718 |     20170728 |      20170725 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-18 00:00:00.000 | 2017-07-25 00:00:00.000 |           7 |
|            43680015 |           491 |            -1 |          328 |       20170718 |     20170728 |      20170725 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-18 00:00:00.000 | 2017-07-25 00:00:00.000 |           7 |
|            43692006 |           221 |            -1 |          338 |       20170729 |     20170808 |      20170805 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-29 00:00:00.000 | 2017-08-05 00:00:00.000 |           7 |
|            43692019 |           221 |            -1 |          330 |       20170729 |     20170808 |      20170805 |                   4 |                1 | 419,4589     | 419,4589          |                         0 | 413,1463                | 413,1463             |            419 |                         1 | 2017-07-29 00:00:00.000 | 2017-08-05 00:00:00.000 |           7 |


Table: Vendas
|   SalesOrderLineKey |   ResellerKey |   CustomerKey |   ProductKey |   OrderDateKey |   DueDateKey |   ShipDateKey |   SalesTerritoryKey |   Order Quantity |   Unit Price | Extended Amount   |   Unit Price Discount Pct | Product Standard Cost   |   Total Product Cost |   Sales Amount |   faturamento |
|--------------------:|--------------:|--------------:|-------------:|---------------:|-------------:|--------------:|--------------------:|-----------------:|-------------:|:------------------|--------------------------:|:------------------------|---------------------:|---------------:|--------------:|
|            43663001 |           510 |            -1 |          322 |       20170707 |     20170717 |      20170714 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |
|            43666001 |           511 |            -1 |          330 |       20170709 |     20170719 |      20170716 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |
|            43666006 |           511 |            -1 |          334 |       20170709 |     20170719 |      20170716 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |
|            43678001 |           203 |            -1 |          322 |       20170718 |     20170728 |      20170725 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |
|            43678003 |           203 |            -1 |          332 |       20170718 |     20170728 |      20170725 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |
|            43678013 |           203 |            -1 |          342 |       20170718 |     20170728 |      20170725 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |
|            43680010 |           491 |            -1 |          324 |       20170718 |     20170728 |      20170725 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |
|            43680015 |           491 |            -1 |          328 |       20170718 |     20170728 |      20170725 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |
|            43692006 |           221 |            -1 |          338 |       20170729 |     20170808 |      20170805 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |
|            43692019 |           221 |            -1 |          330 |       20170729 |     20170808 |      20170805 |                   4 |                1 |          419 | 419,4589          |                         0 | 413,1463                |              413.146 |            419 |           419 |

 


tables: name: categorias
data: categorias.csv
name: dCalendario 1
data: dCalendario 1.csv
name: DimAcessorios
data: DimAcessorios.csv
name: DimBikes
data: DimBikes.csv
name: DimCliente
data: DimCliente.csv
name: DimComponente
data: DimComponente.csv
name: DimData
data: DimData.csv
name: DimRegiao
data: DimRegiao.csv
name: Sales Amount
data: Sales Amount.csv
name: Vendas
data: Vendas.csv
label: Vendas
CustomerKey
DimCliente
CustomerKey
Vendas
ProductKey
DimAcessorios
ProductKey
Vendas
SalesTerritoryKey
DimRegiao
SalesTerritoryKey
Vendas
DueDateKey
DimData
DateKey
Vendas
ProductKey
DimBikes
ProductKey
Vendas
ProductKey
DimComponente
ProductKey
Sales Amount
SalesOrderLineKey
Vendas
SalesOrderLineKey
output: {
    "joins": [
        {
            "from_table": "Vendas",
            "from_column": "CustomerKey",
            "to_table": "DimCliente",
            "to_column": "CustomerKey"
        },
        {
            "from_table": "Vendas",
            "from_column": "ProductKey",
            "to_table": "DimAcessorios",
            "to_column": "ProductKey"
        },
        {
            "from_table": "Vendas",
            "from_column": "SalesTerritoryKey",
            "to_table": "DimRegiao",
            "to_column": "SalesTerritoryKey"
        },
        {
            "from_table": "Vendas",
            "from_column": "DueDateKey",
            "to_table": "DimData",
            "to_column": "DateKey"
        },
        {
            "from_table": "Vendas",
            "from_column": "ProductKey",
            "to_table": "DimBikes",
            "to_column": "ProductKey"
        },
        {
            "from_table": "Vendas",
            "from_column": "ProductKey",
            "to_table": "DimComponente",
            "to_column": "ProductKey"
        },
        {
            "from_table": "Sales Amount",
            "from_column": "SalesOrderLineKey",
            "to_table": "Vendas",
            "to_column": "SalesOrderLineKey"
        }
    ]
}