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: City
|   CityID | City        |
|---------:|:------------|
|        1 | Boulder     |
|        2 | Des Moines  |
|        3 | Provo       |
|        4 | Fontana     |
|        5 | Gainesville |
|        6 | Garland     |
|        7 | Rockford    |
|        8 | Naperville  |
|        9 | Minneapolis |
|       10 | Elk Grove   |


Table: Customer
|   CustomerID | Customer      | ServiceChannel   |   CityID |
|-------------:|:--------------|:-----------------|---------:|
|        50174 | Customer 1812 | GROCERY STORE    |       52 |
|        51678 | Customer 2792 | GROCERY STORE    |       52 |
|        52042 | Customer 4813 | GROCERY STORE    |       52 |
|        52360 | Customer 352  | GROCERY STORE    |       52 |
|        52435 | Customer 2212 | GROCERY STORE    |       52 |
|        53185 | Customer 1833 | GROCERY STORE    |       52 |
|        54971 | Customer 5301 | GROCERY STORE    |       52 |
|        57543 | Customer 8295 | GROCERY STORE    |       52 |
|        58663 | Customer 911  | GROCERY STORE    |       52 |
|        59794 | Customer 536  | GROCERY STORE    |       52 |


Table: Measure Table
| Column   |
|----------|


Table: Orders
| OrderDate               |   OrderID | ScheduledDeliveryDate   | e-BL_IssuedDate         | ActualDeliveryDate      |   SalespersonID |   CustomerID |   Returns |   Delivery Time |
|:------------------------|----------:|:------------------------|:------------------------|:------------------------|----------------:|-------------:|----------:|----------------:|
| 2020-08-07 00:00:00.000 |   5763782 | 2020-08-10 00:00:00.000 | 2020-08-07 00:00:00.000 | 2020-08-08 00:00:00.000 |             201 |       167104 |         0 |               1 |
| 2020-08-06 00:00:00.000 |   5762983 | 2020-08-09 00:00:00.000 | 2020-08-06 00:00:00.000 | 2020-07-08 00:00:00.000 |             201 |       167104 |         0 |             -29 |
| 2020-08-03 00:00:00.000 |   5760040 | 2020-08-06 00:00:00.000 | 2020-08-03 00:00:00.000 | 2020-04-08 00:00:00.000 |             201 |       167104 |         0 |            -117 |
| 2020-07-24 00:00:00.000 |   5754858 | 2020-07-27 00:00:00.000 | 2020-07-24 00:00:00.000 | 2020-07-25 00:00:00.000 |             201 |       167104 |         0 |               1 |
| 2020-07-20 00:00:00.000 |   5751107 | 2020-07-23 00:00:00.000 | 2020-07-20 00:00:00.000 | 2020-07-21 00:00:00.000 |             201 |       167104 |         0 |               1 |
| 2020-07-15 00:00:00.000 |   5748616 | 2020-07-18 00:00:00.000 | 2020-07-15 00:00:00.000 | 2020-07-16 00:00:00.000 |             201 |       167104 |         0 |               1 |
| 2020-07-07 00:00:00.000 |   5743684 | 2020-07-10 00:00:00.000 | 2020-07-08 00:00:00.000 | 2020-09-07 00:00:00.000 |             201 |       167104 |         0 |              62 |
| 2020-07-03 00:00:00.000 |   5742382 | 2020-07-06 00:00:00.000 | 2020-07-06 00:00:00.000 | 2020-07-07 00:00:00.000 |             201 |       167104 |         0 |               4 |
| 2020-07-03 00:00:00.000 |   5742383 | 2020-07-06 00:00:00.000 | 2020-07-06 00:00:00.000 | 2020-07-07 00:00:00.000 |             201 |       167104 |         0 |               4 |
| 2020-06-29 00:00:00.000 |   5739394 | 2020-07-02 00:00:00.000 | 2020-06-29 00:00:00.000 | 2020-06-30 00:00:00.000 |             201 |       167104 |         0 |               1 |


Table: Salesperson
|   SalespersonID | Salesperson   | Team          |
|----------------:|:--------------|:--------------|
|            3405 | ITP           | COAST         |
|            3630 | GSP           | COAST         |
|            3875 | ITP-CEN       | VALLEY        |
|            3523 | BCA-CMB       | COAST         |
|            3846 | ICR           | SOUTH         |
|            3522 | ITJ-CTR       | COAST         |
|            3491 | TLV-7         | TELESALES     |
|            3911 | JLE-CON       | NORTH         |
|            3876 | BCN           | SOUTH         |
|             224 | KA-CRC        | SOUTH MC / KA |

 


tables: name: City
data: City.csv
name: Customer
data: Customer.csv
name: Measure Table
data: Measure Table.csv
name: Orders
data: Orders.csv
name: Salesperson
data: Salesperson.csv
label: Customer
CityID
City
CityID
Orders
CustomerID
Customer
CustomerID
Orders
SalespersonID
Salesperson
SalespersonID
output: {
    "joins": [
        {
            "from_table": "Customer",
            "from_column": "CityID",
            "to_table": "City",
            "to_column": "CityID"
        },
        {
            "from_table": "Orders",
            "from_column": "CustomerID",
            "to_table": "Customer",
            "to_column": "CustomerID"
        },
        {
            "from_table": "Orders",
            "from_column": "SalespersonID",
            "to_table": "Salesperson",
            "to_column": "SalespersonID"
        }
    ]
}