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: Absence
|   EmpID | AbsenceStartDate        | AbsenceEndDate          | AbsenceType            | AbsenceReason   |   AbsenceHours |   Uncertified Sick Leave Days |   Vacation Leave Days |
|--------:|:------------------------|:------------------------|:-----------------------|:----------------|---------------:|------------------------------:|----------------------:|
|   11000 | 2017-01-14 00:00:00.000 | 2017-01-16 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |
|   11030 | 2017-05-20 00:00:00.000 | 2017-05-22 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |
|   11076 | 2017-05-20 00:00:00.000 | 2017-05-22 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |
|   11090 | 2017-05-20 00:00:00.000 | 2017-05-22 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |
|   11073 | 2017-05-22 00:00:00.000 | 2017-05-24 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |
|   11053 | 2017-05-22 00:00:00.000 | 2017-05-24 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |
|   11016 | 2017-06-12 00:00:00.000 | 2017-06-14 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |
|   11017 | 2017-06-12 00:00:00.000 | 2017-06-14 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |
|   11021 | 2017-06-12 00:00:00.000 | 2017-06-14 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |
|   11022 | 2017-06-12 00:00:00.000 | 2017-06-14 00:00:00.000 | Uncertified Sick Leave | Flu             |            7.5 |                             2 |                     0 |


Table: AgeGroup
|   AgeGroupID | AgeGroup   |
|-------------:|:-----------|
|            1 | <30        |
|            2 | 30-49      |
|            3 | 50+        |


Table: Dates
| Date                    |   Year | Month Name   |   Month Number | Weekday   |   Weekday number | Year Month   | Quarter   |
|:------------------------|-------:|:-------------|---------------:|:----------|-----------------:|:-------------|:----------|
| 2017-07-01 00:00:00.000 |   2017 | Jul          |              7 | Saturday  |                7 | Jul 17       | Q3        |
| 2017-07-02 00:00:00.000 |   2017 | Jul          |              7 | Sunday    |                1 | Jul 17       | Q3        |
| 2017-07-03 00:00:00.000 |   2017 | Jul          |              7 | Monday    |                2 | Jul 17       | Q3        |
| 2017-07-04 00:00:00.000 |   2017 | Jul          |              7 | Tuesday   |                3 | Jul 17       | Q3        |
| 2017-07-05 00:00:00.000 |   2017 | Jul          |              7 | Wednesday |                4 | Jul 17       | Q3        |
| 2017-07-06 00:00:00.000 |   2017 | Jul          |              7 | Thursday  |                5 | Jul 17       | Q3        |
| 2017-07-07 00:00:00.000 |   2017 | Jul          |              7 | Friday    |                6 | Jul 17       | Q3        |
| 2017-07-08 00:00:00.000 |   2017 | Jul          |              7 | Saturday  |                7 | Jul 17       | Q3        |
| 2017-07-09 00:00:00.000 |   2017 | Jul          |              7 | Sunday    |                1 | Jul 17       | Q3        |
| 2017-07-10 00:00:00.000 |   2017 | Jul          |              7 | Monday    |                2 | Jul 17       | Q3        |


Table: Department
|   DeptID | Department           |
|---------:|:---------------------|
|        1 | Admin Offices        |
|        2 | Executive Office     |
|        3 | IT/IS                |
|        4 | Software Engineering |
|        5 | Production           |
|        6 | Sales                |
|        7 | Human Resources      |


Table: Education
|   EduID | Education       |
|--------:|:----------------|
|       1 | Master Degree   |
|       2 | Bachelor Degree |
|       3 | Certificate I   |
|       4 | Certificate II  |
|       5 | Diploma         |


Table: Emp Salary
|   EmpID | PaymentDate             |   EmpSalary | SalartRange      |
|--------:|:------------------------|------------:|:-----------------|
|   11025 | 2017-01-25 00:00:00.000 |       16000 | (B) 10000-20000K |
|   11029 | 2017-01-25 00:00:00.000 |       16000 | (B) 10000-20000K |
|   11031 | 2017-01-25 00:00:00.000 |       16000 | (B) 10000-20000K |
|   11025 | 2017-02-25 00:00:00.000 |       16000 | (B) 10000-20000K |
|   11029 | 2017-02-25 00:00:00.000 |       16000 | (B) 10000-20000K |
|   11031 | 2017-02-25 00:00:00.000 |       16000 | (B) 10000-20000K |
|   11025 | 2017-03-25 00:00:00.000 |       16000 | (B) 10000-20000K |
|   11029 | 2017-03-25 00:00:00.000 |       16000 | (B) 10000-20000K |
|   11031 | 2017-03-25 00:00:00.000 |       16000 | (B) 10000-20000K |
|   11040 | 2017-03-25 00:00:00.000 |       16000 | (B) 10000-20000K |


Table: Employee Engagement
|   EmpID | Response Date           | Employee Engagement   |   Score |
|--------:|:------------------------|:----------------------|--------:|
|   11007 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |
|   11011 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |
|   11012 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |
|   11013 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |
|   11014 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |
|   11015 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |
|   11016 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |
|   11017 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |
|   11018 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |
|   11019 | 2017-12-01 00:00:00.000 | Best Effort At Work   |       4 |


Table: Employees
|   EmpID | EmpFirstName   | EmpLastName   | EmpFullName    | DateOfBirth             | HireDate                |   EduID |   DeptID | Gender   |   Age |   AgeGroup | MaritalStatus   |   PayTypeID |   EthnicGroupID |   PositionID | TermDate   |
|--------:|:---------------|:--------------|:---------------|:------------------------|:------------------------|--------:|---------:|:---------|------:|-----------:|:----------------|------------:|----------------:|-------------:|:-----------|
|   11012 | Lauren         | Walker        | Lauren Walker  | 1991-09-16 00:00:00.000 | 2017-01-01 00:00:00.000 |       5 |        6 | F        |    29 |          1 | M               |           1 |               4 |           19 |            |
|   11014 | Sydney         | Bennett       | Sydney Bennett | 2000-08-26 00:00:00.000 | 2017-01-01 00:00:00.000 |       5 |        6 | F        |    20 |          1 | S               |           1 |               6 |           19 |            |
|   11015 | Chloe          | Young         | Chloe Young    | 2001-02-08 00:00:00.000 | 2017-01-01 00:00:00.000 |       5 |        6 | F        |    19 |          1 | S               |           1 |               6 |           19 |            |
|   11019 | Luke           | Lal           | Luke Lal       | 2000-04-05 00:00:00.000 | 2017-01-01 00:00:00.000 |       5 |        6 | M        |    20 |          1 | S               |           1 |               1 |           19 |            |
|   11022 | Ethan          | Zhang         | Ethan Zhang    | 1998-03-12 00:00:00.000 | 2017-01-01 00:00:00.000 |       5 |        6 | M        |    22 |          1 | M               |           1 |               3 |           19 |            |
|   11023 | Seth           | Edwards       | Seth Edwards   | 1999-01-07 00:00:00.000 | 2017-01-01 00:00:00.000 |       5 |        6 | M        |    21 |          1 | M               |           1 |               5 |           19 |            |
|   11027 | Jessie         | Zhao          | Jessie Zhao    | 2001-06-18 00:00:00.000 | 2017-01-01 00:00:00.000 |       1 |        6 | M        |    19 |          1 | M               |           1 |               4 |           19 |            |
|   11029 | Jimmy          | Moreno        | Jimmy Moreno   | 1999-04-14 00:00:00.000 | 2017-01-01 00:00:00.000 |       4 |        6 | M        |    21 |          1 | M               |           1 |               2 |           19 |            |
|   11030 | Bethany        | Yuan          | Bethany Yuan   | 1999-09-21 00:00:00.000 | 2017-01-01 00:00:00.000 |       5 |        6 | F        |    21 |          1 | M               |           1 |               6 |           19 |            |
|   11031 | Theresa        | Ramos         | Theresa Ramos  | 2000-10-10 00:00:00.000 | 2017-01-01 00:00:00.000 |       5 |        6 | F        |    20 |          1 | M               |           1 |               5 |           19 |            |


Table: Ethnicity
|   EthnicGroupID | Ethnicity   |
|----------------:|:------------|
|               1 | Group A     |
|               2 | Group B     |
|               3 | Group C     |
|               4 | Group D     |
|               5 | Group E     |
|               6 | Group F     |
|               7 | Group G     |


Table: img url
|   EmpID | URL                                                                                |
|--------:|:-----------------------------------------------------------------------------------|
|   11205 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |
|   11044 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |
|   11229 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |
|   11093 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |
|   11050 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |
|   11025 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |
|   11222 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |
|   11202 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |
|   11244 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |
|   11196 | https://www.seekpng.com/png/detail/303-3030720_leo-messi-lionel-messi-png-face.png |


Table: PayType
|   PayTypeID | PayType       |
|------------:|:--------------|
|           1 | Contract Temp |
|           2 | Permanent     |


Table: Position
|   PositionID | Position          |
|-------------:|:------------------|
|            1 | CEO               |
|            2 | COO               |
|            3 | CFO               |
|            4 | CMO               |
|            5 | CTO               |
|            6 | CIO               |
|            7 | Marketing manager |
|            8 | Product manager   |
|            9 | Finance manager   |
|           10 | HR manager        |

 


tables: name: Absence
data: Absence.csv
name: AgeGroup
data: AgeGroup.csv
name: Dates
data: Dates.csv
name: Department
data: Department.csv
name: Education
data: Education.csv
name: Emp Salary
data: Emp Salary.csv
name: Employee Engagement
data: Employee Engagement.csv
name: Employees
data: Employees.csv
name: Ethnicity
data: Ethnicity.csv
name: img url
data: img url.csv
name: PayType
data: PayType.csv
name: Position
data: Position.csv
label: Employees
EthnicGroupID
Ethnicity
EthnicGroupID
Employees
PositionID
Position
PositionID
Employees
DeptID
Department
DeptID
Employees
EduID
Education
EduID
img url
EmpID
Employees
EmpID
Employees
AgeGroup
AgeGroup
AgeGroupID
Employees
PayTypeID
PayType
PayTypeID
Employee Engagement
EmpID
Employees
EmpID
Emp Salary
EmpID
Employees
EmpID
output: {
    "joins": [
        {
            "from_table": "Employees",
            "from_column": "EthnicGroupID",
            "to_table": "Ethnicity",
            "to_column": "EthnicGroupID"
        },
        {
            "from_table": "Employees",
            "from_column": "PositionID",
            "to_table": "Position",
            "to_column": "PositionID"
        },
        {
            "from_table": "Employees",
            "from_column": "DeptID",
            "to_table": "Department",
            "to_column": "DeptID"
        },
        {
            "from_table": "Employees",
            "from_column": "EduID",
            "to_table": "Education",
            "to_column": "EduID"
        },
        {
            "from_table": "img url",
            "from_column": "EmpID",
            "to_table": "Employees",
            "to_column": "EmpID"
        },
        {
            "from_table": "Employees",
            "from_column": "AgeGroup",
            "to_table": "AgeGroup",
            "to_column": "AgeGroupID"
        },
        {
            "from_table": "Employees",
            "from_column": "PayTypeID",
            "to_table": "PayType",
            "to_column": "PayTypeID"
        },
        {
            "from_table": "Employee Engagement",
            "from_column": "EmpID",
            "to_table": "Employees",
            "to_column": "EmpID"
        },
        {
            "from_table": "Emp Salary",
            "from_column": "EmpID",
            "to_table": "Employees",
            "to_column": "EmpID"
        }
    ]
}