![profile pic](https://preparesh-arbpfvdsfpcdg8a0.z01.azurefd.net/images/companies/profile/undefined.png)
![profile pic](https://preparesh-arbpfvdsfpcdg8a0.z01.azurefd.net/images/companies/profile/undefined.png)
What steps are involved in creating a dashboard in Tableau?
Please sign-in to view the solution
Given two tables named Tickets
and Employees
, where Tickets
contains columns id
, employee_id
, and status
, and Employees
contains columns id
and name
, write a SQL query to find the employee who is solving the most tickets. The result should include the employee's name, the number of tickets they have solved, and their rank based on the number of tickets solved.
Input:
`Tickets` table:
| id | employee_id | status |
|----|-------------|---------|
| 1 | 1 | solved |
| 2 | 2 | pending |
| 3 | 1 | solved |
| 4 | 2 | solved |
| 5 | 1 | solved |
`Employees` table:
| id | name |
|----|--------------|
| 1 | John |
| 2 | Jane |
Output: The query should return the employee name, the number of tickets they have solved, and their rank.
Please sign-in to view the solution
What is the difference between Extract and Live in Tableau?
Please sign-in to view the solution
How do you perform transpose operations in SQL to convert rows into columns?
Input:
Consider a table named `Sales` with columns `month`, `employee_id`, and `amount`:
| month | employee_id | amount |
|-------|--------------|--------|
| Jan | 1 | 100 |
| Jan | 2 | 150 |
| Feb | 1 | 200 |
| Feb | 2 | 250 |
Output:
Transpose the table to show each month as a separate column with amounts for each employee:
| employee_id | Jan | Feb |
|-------------|-----|-----|
| 1 | 100 | 200 |
| 2 | 150 | 250 |
Please sign-in to view the solution
What is a xyz
in Tableau and what does it do?
Please sign-in to view the solution
What factors should be used in generating a forecast for an item, and what should be the process of generation?
Please sign-in to view the solution
How would you identify and address potentially under-performing predictive models in a production environment?
Please sign-in to view the solution
How would you diagnose and resolve issues when a business intelligence report breaks in a production environment?
Please sign-in to view the solution
Given three tables named Products
, Sales
, and Customers
, write an SQL query to find the top 5 products with the highest total sales from the last month. The query should involve joins between these tables and should account for any discounts applied. Also, handle any potential NULL values in the total sales calculation.
Input:
- `Products` table:
| id | name | price |
|----|------------|-------|
| 1 | Product A | 10 |
| 2 | Product B | 20 |
| ...| ... | ... |
- `Sales` table:
| id | product_id | customer_id | quantity | discount | sale_date |
|----|------------|-------------|----------|----------|-----------|
| 1 | 1 | 1 | 5 | 0.1 | 2023-09-15|
| 2 | 2 | 2 | 3 | 0.0 | 2023-09-20|
| ...| ... | ... | ... | ... | ... |
- `Customers` table:
| id | name |
|----|------------|
| 1 | John |
| 2 | Jane |
| ...| ... |
Output: The query should return the product name and the total sales amount in descending order of sales, limited to the top 5 products.
Please sign-in to view the solution
Write an SQL query to retrieve the names of customers who have purchased more than 5 products in total within the last 30 days. The query should use joins to connect the Customers
, Orders
, and OrderDetails
tables.
Input:
- `Customers` table:
| id | name |
|----|------------|
| 1 | John |
| 2 | Jane |
| ...| ... |
- `Orders` table:
| id | customer_id | order_date |
|----|-------------|------------|
| 1 | 1 | 2023-09-25 |
| 2 | 2 | 2023-09-20 |
| ...| ... | ... |
- `OrderDetails` table:
| id | order_id | product_id | quantity |
|----|----------|------------|----------|
| 1 | 1 | 1 | 3 |
| 2 | 1 | 2 | 4 |
| 3 | 2 | 1 | 6 |
| ...| ... | ... | ... |
Output: The query should return the names of customers who have purchased more than 5 products in total within the last 30 days.
Please sign-in to view the solution
What is the difference between 'WHERE' and 'HAVING' filters in SQL? Provide an example to illustrate your point.
Please sign-in to view the solution
How would you handle skewed distributions and imbalanced classes in a dataset intended for machine learning? Provide specific techniques and tools you would use.
Please sign-in to view the solution
What is SQL? Explain the differences between the DELETE, TRUNCATE, and DROP commands in SQL.
Please sign-in to view the solution
Using the dataset above, write an Excel formula to calculate the total sales made by each salesperson. Provide the calculated total sales for "John."
Input Data:
Consider a dataset in Excel with the following columns: `Salesperson`, `Product`, `Quantity`, and `Price`.
**Data**
| A | B | C | D |
|------------|--------|----------|--------|
| Salesperson| Product| Quantity | Price |
| John | Widget | 10 | 15 |
| Jane | Gadget | 5 | 20 |
| John | Gizmo | 7 | 30 |
| Alice | Widget | 3 | 15 |
| Jane | Gadget | 10 | 20 |
Please sign-in to view the solution
What is the maximum number of IF statements you can nest within a single formula in Excel? Provide an example of a nested IF statement.
Please sign-in to view the solution