75.4k views
0 votes
You have a salary table containing departments (DEPARTMENT column) and salaries ( SALARY column )How do you calculate the average salaries for each department in the Query transform in SAP Data Services?

1 Answer

6 votes

Final answer:

To calculate average salaries for each department in the Query transform in SAP Data Services, use the AVG() function along with the GROUP BY clause.

Step-by-step explanation:

To calculate the average salaries for each department in the Query transform in SAP Data Services, you can use the AVG() function along with the GROUP BY clause. Here's an example:

SELECT DEPARTMENT, AVG(SALARY) AS AVERAGE_SALARY FROM SalaryTable GROUP BY DEPARTMENT;

This query will group the salaries by department and calculate the average salary for each department.

User Fonti
by
8.0k points