Skip to content
Advertisement

How to get Average Salary of SQL HourlyPayRate Column?

I am working on creating a SSRS report and I want to get the Average of the HourlyPayRate Column that I have(in my case statement). I am a self learner of SQL and was wondering how I can get the AVG of the HourlyPayRate in a new table(If even possible).

What I am doing is doing is when the Employee’s Salary class is an ‘S’ for salary or if the pay rate is greater than 1000 then take the pay rate / 2080 the number of hours in a year.

Advertisement

Answer

Could you not just do some form of this? I have removed your variables and where clause but you can adjust as needed:

User contributions licensed under: CC BY-SA
5 People found this is helpful
Advertisement