{
  "format": "dataset-manifest/1",
  "slug": "workplace-insights",
  "version": 2,
  "seed": "workplace-insights:1",
  "spec": {
    "format": "dataset/1",
    "slug": "workplace-insights",
    "name": "Workplace Insights",
    "tagline": "Employee records, timesheets, salary information, benefits, and performance reviews from an HR consultancy.",
    "description": "Employees track their work hours, ensuring accurate payroll and project management in this HR consultancy focused on optimizing workforce management and enhancing employee satisfaction. Using detailed timesheets, each employee records their daily hours worked, providing vital data for understanding productivity patterns and labor costs. Salaries reflect the core compensation structure for the workforce, while a range of benefits offers insights into employee perks and engagement strategies. The consultancy also captures employee reviews, which serve as a feedback mechanism to inform training, development, and overall workplace culture improvements.\n\nEach row in the employees table represents an individual worker, detailing their unique identifier, position, and departmental affiliation. The timesheets table links to employees, illustrating the hours worked by each employee, which can be critical for analyzing workload, overtime, and project assignments. Salaries provide a financial perspective, showcasing how compensation varies across roles and the potential impact of performance bonuses for select individuals. Benefits are associated with employees to give a comprehensive view of the total compensation package, while reviews allow the consultancy to evaluate employee satisfaction and areas for improvement. The interconnectedness of these tables allows for rich analysis, revealing how employee performance correlates with compensation and job satisfaction.\n\nThis data is particularly useful for practitioners looking to answer questions regarding employee productivity trends, compensation fairness, and the effectiveness of benefits programs. Analysts can explore how various factors, such as salary structure and employee feedback, contribute to overall workforce engagement. Practicing with this synthetic dataset provides a realistic backdrop to hone skills in data analysis, relational database management, and workforce analytics.",
    "domain": "hr",
    "shape": "star-schema",
    "useCases": [
      "bi-dashboards",
      "analytics-demo"
    ],
    "keywords": [
      "employee management",
      "HR analytics",
      "timesheets",
      "salary",
      "benefits",
      "performance reviews"
    ],
    "locale": "en",
    "license": "CC0-1.0",
    "version": 1,
    "tables": {
      "employees": {
        "description": "This table contains records of employees, including their identifiers, names, and contact details, serving as the central point for other tables.",
        "rows": 200,
        "columns": {
          "id": {
            "kind": "pk",
            "description": "Unique identifier for the employee."
          },
          "first_name": {
            "kind": "firstName",
            "description": "Employee's first name."
          },
          "last_name": {
            "kind": "lastName",
            "description": "Employee's last name."
          },
          "email": {
            "kind": "email",
            "from": [
              "first_name",
              "last_name"
            ],
            "description": "Employee's email address."
          },
          "hire_date": {
            "kind": "date",
            "from": "2020-01-01",
            "to": "2023-12-31",
            "description": "Date the employee was hired.",
            "trend": "growing"
          }
        }
      },
      "timesheets": {
        "description": "This table logs the hours worked by employees, linking to the employees table and allowing for time management analysis.",
        "rows": {
          "per": "employees",
          "via": "employee_id",
          "min": 1,
          "max": 10,
          "skew": "long-tail"
        },
        "columns": {
          "id": {
            "kind": "pk",
            "description": "Unique identifier for the timesheet entry."
          },
          "employee_id": {
            "kind": "fk",
            "ref": "employees.id",
            "description": "Reference to the employee."
          },
          "work_date": {
            "kind": "date",
            "from": "2023-01-01",
            "to": "2024-12-31",
            "description": "Date of work logged."
          },
          "hours_worked": {
            "kind": "decimal",
            "min": 0,
            "max": 24,
            "scale": 2,
            "description": "Total hours worked on the specified date."
          }
        }
      },
      "salaries": {
        "description": "This table records the salary details for each employee, allowing for analysis of compensation across the workforce.",
        "rows": {
          "per": "employees",
          "via": "employee_id",
          "min": 1,
          "max": 1,
          "skew": "flat"
        },
        "columns": {
          "id": {
            "kind": "pk",
            "description": "Unique identifier for the salary record."
          },
          "employee_id": {
            "kind": "fk",
            "ref": "employees.id",
            "description": "Reference to the employee."
          },
          "base_salary": {
            "kind": "decimal",
            "min": 35000,
            "max": 150000,
            "scale": 2,
            "description": "Annual base salary of the employee.",
            "distribution": "long-tail"
          },
          "bonus": {
            "kind": "decimal",
            "min": 0,
            "max": 20000,
            "scale": 2,
            "nullable": true,
            "description": "Performance bonus, if applicable.",
            "distribution": "long-tail"
          }
        }
      },
      "benefits": {
        "description": "This table contains the benefits packages for employees, detailing the types of benefits they receive.",
        "rows": {
          "per": "employees",
          "via": "employee_id",
          "min": 1,
          "max": 1,
          "skew": "flat"
        },
        "columns": {
          "id": {
            "kind": "pk",
            "description": "Unique identifier for the benefits record."
          },
          "employee_id": {
            "kind": "fk",
            "ref": "employees.id",
            "description": "Reference to the employee."
          },
          "health_insurance": {
            "kind": "bool",
            "trueRate": 0.9,
            "description": "Whether the employee has health insurance."
          },
          "start_date": {
            "kind": "date",
            "from": "2023-01-01",
            "to": "2024-12-31",
            "description": "Start date of benefits coverage.",
            "trend": "seasonal"
          }
        }
      },
      "reviews": {
        "description": "This table holds employee performance review data, including feedback and ratings.",
        "rows": {
          "per": "employees",
          "via": "employee_id",
          "min": 1,
          "max": 3,
          "skew": "long-tail"
        },
        "columns": {
          "id": {
            "kind": "pk",
            "description": "Unique identifier for the review record."
          },
          "employee_id": {
            "kind": "fk",
            "ref": "employees.id",
            "description": "Reference to the employee."
          },
          "review_date": {
            "kind": "date",
            "from": "2023-01-01",
            "to": "2024-12-31",
            "description": "Date when the review took place.",
            "trend": "seasonal"
          },
          "rating": {
            "kind": "int",
            "min": 1,
            "max": 5,
            "description": "Performance rating given during the review.",
            "distribution": "high"
          },
          "comments": {
            "kind": "sentence",
            "description": "Feedback comments from the review."
          }
        }
      }
    },
    "structure": "multi-table",
    "traits": [
      "timestamped",
      "monetary",
      "categorical"
    ],
    "analysisQuestions": [
      "What is the average salary of employees by department?",
      "How many hours did employees work on average per week?",
      "What performance ratings correlate with employee bonuses?",
      "Which benefits are most valued by employees?",
      "How do employee reviews impact training and development strategies?"
    ],
    "suggestedQueries": [
      {
        "title": "Join Employees and Timesheets",
        "sql": "SELECT e.first_name, e.last_name, t.work_date, t.hours_worked FROM employees e JOIN timesheets t ON e.id = t.employee_id;",
        "dialect": "postgres"
      },
      {
        "title": "Average Salary by Employee",
        "sql": "SELECT e.first_name, e.last_name, s.base_salary FROM employees e JOIN salaries s ON e.id = s.employee_id;",
        "dialect": "postgres"
      },
      {
        "title": "Total Hours Worked by Employee",
        "sql": "SELECT e.first_name, e.last_name, SUM(t.hours_worked) AS total_hours FROM employees e JOIN timesheets t ON e.id = t.employee_id GROUP BY e.id;",
        "dialect": "postgres"
      },
      {
        "title": "Salary Distribution and Bonuses",
        "sql": "SELECT s.base_salary, s.bonus FROM salaries s WHERE s.bonus IS NOT NULL;",
        "dialect": "postgres"
      },
      {
        "title": "Performance Ratings Analysis",
        "sql": "SELECT e.first_name, e.last_name, AVG(r.rating) AS average_rating FROM employees e JOIN reviews r ON e.id = r.employee_id GROUP BY e.id;",
        "dialect": "postgres"
      }
    ],
    "usageScenarios": [
      {
        "title": "HR Analysts",
        "body": "HR analysts can utilize the Workplace Insights dataset to generate reports on employee performance and satisfaction metrics. By analyzing the relationships between employee hours worked and their performance reviews, analysts can provide actionable insights to management on optimizing workforce strategies."
      },
      {
        "title": "Compensation Managers",
        "body": "Compensation managers can leverage this dataset to assess salary competitiveness and structure. By comparing base salaries with performance ratings and employee feedback, they can identify areas needing adjustments and ensure fair compensation across the organization."
      },
      {
        "title": "Training and Development Coordinators",
        "body": "Training and development coordinators can utilize the insights from performance reviews and employee feedback to tailor training programs effectively. By understanding which benefits and reviews correlate with employee satisfaction, they can design initiatives that enhance workforce engagement."
      },
      {
        "title": "Business Intelligence Developers",
        "body": "Business intelligence developers can use the Workplace Insights dataset to create visual dashboards that monitor key HR metrics. By visualizing trends in employee hours, salaries, and reviews, they can help organizations make data-driven decisions to improve their HR practices."
      }
    ]
  },
  "counts": {
    "employees": 200,
    "benefits": 200,
    "reviews": 311,
    "salaries": 200,
    "timesheets": 773
  },
  "stats": {
    "employees": {
      "rows": 200,
      "columns": {
        "id": {
          "nulls": 0,
          "distinct": 200,
          "min": 1,
          "max": 200
        },
        "first_name": {
          "nulls": 0,
          "distinct": 74,
          "min": "Alice",
          "max": "Zoe"
        },
        "last_name": {
          "nulls": 0,
          "distinct": 73,
          "min": "Adams",
          "max": "Zhang"
        },
        "email": {
          "nulls": 0,
          "distinct": 198
        },
        "hire_date": {
          "nulls": 0,
          "distinct": 188,
          "min": "2020-01-20",
          "max": "2023-12-30"
        }
      }
    },
    "timesheets": {
      "rows": 773,
      "columns": {
        "id": {
          "nulls": 0,
          "distinct": 773,
          "min": 1,
          "max": 773
        },
        "employee_id": {
          "nulls": 0,
          "distinct": 200,
          "min": 1,
          "max": 200
        },
        "work_date": {
          "nulls": 0,
          "distinct": 483,
          "min": "2023-01-01",
          "max": "2024-12-31"
        },
        "hours_worked": {
          "nulls": 0,
          "distinct": 644,
          "min": 0,
          "max": 23.94
        }
      }
    },
    "salaries": {
      "rows": 200,
      "columns": {
        "id": {
          "nulls": 0,
          "distinct": 200,
          "min": 1,
          "max": 200
        },
        "employee_id": {
          "nulls": 0,
          "distinct": 200,
          "min": 1,
          "max": 200
        },
        "base_salary": {
          "nulls": 0,
          "distinct": 200,
          "min": 35000.51,
          "max": 149305.94
        },
        "bonus": {
          "nulls": 19,
          "distinct": 181,
          "min": 0.09,
          "max": 19807.52
        }
      }
    },
    "benefits": {
      "rows": 200,
      "columns": {
        "id": {
          "nulls": 0,
          "distinct": 200,
          "min": 1,
          "max": 200
        },
        "employee_id": {
          "nulls": 0,
          "distinct": 200,
          "min": 1,
          "max": 200
        },
        "health_insurance": {
          "nulls": 0,
          "distinct": 2,
          "min": "false",
          "max": "true"
        },
        "start_date": {
          "nulls": 0,
          "distinct": 174,
          "min": "2023-01-01",
          "max": "2024-12-29"
        }
      }
    },
    "reviews": {
      "rows": 311,
      "columns": {
        "id": {
          "nulls": 0,
          "distinct": 311,
          "min": 1,
          "max": 311
        },
        "employee_id": {
          "nulls": 0,
          "distinct": 200,
          "min": 1,
          "max": 200
        },
        "review_date": {
          "nulls": 0,
          "distinct": 242,
          "min": "2023-01-01",
          "max": "2024-12-29"
        },
        "rating": {
          "nulls": 0,
          "distinct": 5,
          "min": 1,
          "max": 5
        },
        "comments": {
          "nulls": 0,
          "distinct": 310
        }
      }
    }
  },
  "artifacts": [
    {
      "file": "csv/employees.csv",
      "format": "csv",
      "table": "employees",
      "key": "datasets/workplace-insights/v2/csv/employees.csv",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/csv/employees.csv",
      "bytes": 10287,
      "sha256": "04cff63f7e83a9302d17c11646da4c53fb09aa7ca93ad59a818b2153f20c5aa9",
      "rows": 200,
      "contentType": "text/csv; charset=utf-8"
    },
    {
      "file": "csv/benefits.csv",
      "format": "csv",
      "table": "benefits",
      "key": "datasets/workplace-insights/v2/csv/benefits.csv",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/csv/benefits.csv",
      "bytes": 4845,
      "sha256": "e47e2ad4bf9147ee5d86bb2e58b4006084ae5ecb8c909917781a821343fdf30a",
      "rows": 200,
      "contentType": "text/csv; charset=utf-8"
    },
    {
      "file": "csv/reviews.csv",
      "format": "csv",
      "table": "reviews",
      "key": "datasets/workplace-insights/v2/csv/reviews.csv",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/csv/reviews.csv",
      "bytes": 24074,
      "sha256": "9e1b835e2174ef7470b044a024026d86696b0cca3e20792255aff18f85c7f7fc",
      "rows": 311,
      "contentType": "text/csv; charset=utf-8"
    },
    {
      "file": "csv/salaries.csv",
      "format": "csv",
      "table": "salaries",
      "key": "datasets/workplace-insights/v2/csv/salaries.csv",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/csv/salaries.csv",
      "bytes": 4938,
      "sha256": "51c305310380168a61024f7398b669aa595a69244911ccdc0f767d8f38e2dfbe",
      "rows": 200,
      "contentType": "text/csv; charset=utf-8"
    },
    {
      "file": "csv/timesheets.csv",
      "format": "csv",
      "table": "timesheets",
      "key": "datasets/workplace-insights/v2/csv/timesheets.csv",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/csv/timesheets.csv",
      "bytes": 19294,
      "sha256": "670c4690c680e85c85bbba94c8a01e4bd3119fa76b285e42a406df9cf11695e4",
      "rows": 773,
      "contentType": "text/csv; charset=utf-8"
    },
    {
      "file": "workplace-insights.json",
      "format": "json",
      "table": null,
      "key": "datasets/workplace-insights/v2/workplace-insights.json",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/workplace-insights.json",
      "bytes": 224899,
      "sha256": "9f95f4965e6a75c7efaf9f73d3ce8ecd5bfb23826cd4d9450924a7e777dff4d5",
      "rows": null,
      "contentType": "application/json; charset=utf-8"
    },
    {
      "file": "sql/postgres.sql",
      "format": "sql-postgres",
      "table": null,
      "key": "datasets/workplace-insights/v2/sql/postgres.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/sql/postgres.sql",
      "bytes": 86735,
      "sha256": "ec6efe5e294a3c043465697805d1b2cc85417838ef58b3e1d3f82c9a3798d773",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "sql/mysql.sql",
      "format": "sql-mysql",
      "table": null,
      "key": "datasets/workplace-insights/v2/sql/mysql.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/sql/mysql.sql",
      "bytes": 85566,
      "sha256": "321b33660554c0e30ef5b4993fe1caa1b969d14819454853a66fb94d0b87c9bc",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "sql/mssql.sql",
      "format": "sql-mssql",
      "table": null,
      "key": "datasets/workplace-insights/v2/sql/mssql.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/sql/mssql.sql",
      "bytes": 88275,
      "sha256": "6786840f8be2a6a204d86dba3d05acb80286a8d64a98a45c63f7bd4fe36b8dd7",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "sql/sqlite.sql",
      "format": "sql-sqlite",
      "table": null,
      "key": "datasets/workplace-insights/v2/sql/sqlite.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/sql/sqlite.sql",
      "bytes": 85397,
      "sha256": "92b1d71a13226dfb322b6451c730d003a8c80874d9ffdf79d8104db47cec9f52",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "prisma/seed.ts",
      "format": "prisma-seed",
      "table": null,
      "key": "datasets/workplace-insights/v2/prisma/seed.ts",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/prisma/seed.ts",
      "bytes": 177108,
      "sha256": "7fc818f3c7281a544cea38cf4ecf14147ecc993636eb5c72a603a95eddbac81d",
      "rows": null,
      "contentType": "application/typescript; charset=utf-8"
    },
    {
      "file": "django/fixtures.json",
      "format": "django-fixture",
      "table": null,
      "key": "datasets/workplace-insights/v2/django/fixtures.json",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/workplace-insights/v2/django/fixtures.json",
      "bytes": 298127,
      "sha256": "7814fee6164b3c424a01b578fec83ec8c00a91323189853bbf272a2a8fdba3c1",
      "rows": null,
      "contentType": "application/json; charset=utf-8"
    }
  ],
  "publishedAt": 1788768103471,
  "updatedAt": 1788787070277
}
