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: Customer Count
| Month Start Date        |   Customer Count |
|:------------------------|-----------------:|
| 2015-11-01 00:00:00.000 |              431 |
| 2014-05-01 00:00:00.000 |              492 |
| 2014-06-01 00:00:00.000 |              271 |
| 2015-07-01 00:00:00.000 |              315 |
| 2013-06-01 00:00:00.000 |              447 |
| 2015-06-01 00:00:00.000 |              331 |
| 2015-02-01 00:00:00.000 |              289 |
| 2016-04-01 00:00:00.000 |              267 |
| 2013-08-01 00:00:00.000 |              364 |
| 2015-08-01 00:00:00.000 |              427 |


Table: Measures
| Value   |
|---------|


Table: Sales CustomerCategories
|   CustomerCategoryID | CustomerCategoryName   |
|---------------------:|:-----------------------|
|                    1 | Agent                  |
|                    5 | Computer Store         |
|                    7 | Corporate              |
|                    8 | General Retailer       |
|                    6 | Gift Store             |
|                    3 | Novelty Shop           |
|                    4 | Supermarket            |
|                    2 | Wholesaler             |


Table: Sales Customers
|   CustomerID | CustomerName                       |   CustomerCategoryID |
|-------------:|:-----------------------------------|---------------------:|
|            1 | Tailspin Toys (Head Office)        |                    3 |
|            2 | Tailspin Toys (Sylvanite, MT)      |                    3 |
|            3 | Tailspin Toys (Peeples Valley, AZ) |                    3 |
|            4 | Tailspin Toys (Medicine Lodge, KS) |                    3 |
|            5 | Tailspin Toys (Gasport, NY)        |                    3 |
|            6 | Tailspin Toys (Jessie, ND)         |                    3 |
|            7 | Tailspin Toys (Frankewing, TN)     |                    3 |
|            8 | Tailspin Toys (Bow Mar, CO)        |                    3 |
|            9 | Tailspin Toys (Netcong, NJ)        |                    3 |
|           10 | Tailspin Toys (Wimbledon, ND)      |                    3 |


Table: Sales OrderLines
|   OrderLineID |   OrderID |   StockItemID | Description                                                              |   Quantity |   UnitPrice |   TaxRate |   PickedQuantity |
|--------------:|----------:|--------------:|:-------------------------------------------------------------------------|-----------:|------------:|----------:|-----------------:|
|          1123 |       429 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |
|          3902 |      1267 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |
|          4065 |      1316 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |
|          6787 |      2117 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |
|          8284 |      2587 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |
|          8707 |      2723 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |
|          9444 |      2946 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |
|         10252 |      3192 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |
|         10929 |      3405 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |
|         12076 |      3762 |            39 | Developer joke mug - inheritance is the OO way to become wealthy (Black) |          7 |          13 |        15 |                7 |


Table: Sales Orders
|   OrderID |   CustomerID |   SalespersonPersonID | OrderDate               | ExpectedDeliveryDate    |   NewCustomerId | Month Start Date        |   Month Ranking |
|----------:|-------------:|----------------------:|:------------------------|:------------------------|----------------:|:------------------------|----------------:|
|     61788 |           16 |                    20 | 2015-11-25 00:00:00.000 | 2015-11-26 00:00:00.000 |              43 | 2015-11-01 00:00:00.000 |              35 |
|     26433 |           22 |                    20 | 2014-05-06 00:00:00.000 | 2014-05-07 00:00:00.000 |              43 | 2014-05-01 00:00:00.000 |              17 |
|     29301 |           44 |                    20 | 2014-06-20 00:00:00.000 | 2014-06-23 00:00:00.000 |              43 | 2014-06-01 00:00:00.000 |              18 |
|     52195 |           54 |                    20 | 2015-07-01 00:00:00.000 | 2015-07-02 00:00:00.000 |              43 | 2015-07-01 00:00:00.000 |              31 |
|      9550 |           58 |                    20 | 2013-06-28 00:00:00.000 | 2013-07-01 00:00:00.000 |              43 | 2013-06-01 00:00:00.000 |               6 |
|     51605 |           60 |                    20 | 2015-06-22 00:00:00.000 | 2015-06-23 00:00:00.000 |              43 | 2015-06-01 00:00:00.000 |              30 |
|     50842 |           60 |                    20 | 2015-06-09 00:00:00.000 | 2015-06-10 00:00:00.000 |              43 | 2015-06-01 00:00:00.000 |              30 |
|     43984 |           68 |                    20 | 2015-02-26 00:00:00.000 | 2015-02-27 00:00:00.000 |              43 | 2015-02-01 00:00:00.000 |              26 |
|     70198 |           71 |                    20 | 2016-04-11 00:00:00.000 | 2016-04-12 00:00:00.000 |              43 | 2016-04-01 00:00:00.000 |              40 |
|     11910 |           72 |                    20 | 2013-08-07 00:00:00.000 | 2013-08-08 00:00:00.000 |              43 | 2013-08-01 00:00:00.000 |               8 |


Table: Warehouse Colors
|   ColorID | ColorName   |
|----------:|:------------|
|         1 | Azure       |
|         2 | Beige       |
|         3 | Black       |
|         4 | Blue        |
|         5 | Charcoal    |
|         6 | Chartreuse  |
|         7 | Cyan        |
|         8 | Dark Brown  |
|         9 | Dark Green  |
|        10 | Fuchsia     |


Table: Warehouse StockItems
|   StockItemID | StockItemName                                        |   SupplierID | ColorID   | Size   |   TaxRate |   UnitPrice |   RecommendedRetailPrice |   TypicalWeightPerUnit |
|--------------:|:-----------------------------------------------------|-------------:|:----------|:-------|----------:|------------:|-------------------------:|-----------------------:|
|             1 | USB missile launcher (Green)                         |           12 |           |        |        15 |        25   |                    37.38 |                   0.3  |
|             2 | USB rocket launcher (Gray)                           |           12 | 12        |        |        15 |        25   |                    37.38 |                   0.3  |
|             3 | Office cube periscope (Black)                        |           12 | 3         |        |        15 |        18.5 |                    27.66 |                   0.25 |
|             4 | USB food flash drive - sushi roll                    |           12 |           |        |        15 |        32   |                    47.84 |                   0.05 |
|             5 | USB food flash drive - hamburger                     |           12 |           |        |        15 |        32   |                    47.84 |                   0.05 |
|             6 | USB food flash drive - hot dog                       |           12 |           |        |        15 |        32   |                    47.84 |                   0.05 |
|             7 | USB food flash drive - pizza slice                   |           12 |           |        |        15 |        32   |                    47.84 |                   0.05 |
|             8 | USB food flash drive - dim sum 10 drive variety pack |           12 |           |        |        15 |       240   |                   358.8  |                   0.5  |
|             9 | USB food flash drive - banana                        |           12 |           |        |        15 |        32   |                    47.84 |                   0.05 |
|            10 | USB food flash drive - chocolate bar                 |           12 |           |        |        15 |        32   |                    47.84 |                   0.05 |

 


tables: name: Customer Count
data: Customer Count.csv
name: Measures
data: Measures.csv
name: Sales CustomerCategories
data: Sales CustomerCategories.csv
name: Sales Customers
data: Sales Customers.csv
name: Sales OrderLines
data: Sales OrderLines.csv
name: Sales Orders
data: Sales Orders.csv
name: Warehouse Colors
data: Warehouse Colors.csv
name: Warehouse StockItems
data: Warehouse StockItems.csv
label: Sales Orders
CustomerID
Sales Customers
CustomerID
Sales OrderLines
OrderID
Sales Orders
OrderID
Sales OrderLines
StockItemID
Warehouse StockItems
StockItemID
Sales Customers
CustomerCategoryID
Sales CustomerCategories
CustomerCategoryID
Warehouse StockItems
ColorID
Warehouse Colors
ColorID
output: {
    "joins": [
        {
            "from_table": "Sales Orders",
            "from_column": "CustomerID",
            "to_table": "Sales Customers",
            "to_column": "CustomerID"
        },
        {
            "from_table": "Sales OrderLines",
            "from_column": "OrderID",
            "to_table": "Sales Orders",
            "to_column": "OrderID"
        },
        {
            "from_table": "Sales OrderLines",
            "from_column": "StockItemID",
            "to_table": "Warehouse StockItems",
            "to_column": "StockItemID"
        },
        {
            "from_table": "Sales Customers",
            "from_column": "CustomerCategoryID",
            "to_table": "Sales CustomerCategories",
            "to_column": "CustomerCategoryID"
        },
        {
            "from_table": "Warehouse StockItems",
            "from_column": "ColorID",
            "to_table": "Warehouse Colors",
            "to_column": "ColorID"
        }
    ]
}