Skip to content
Advertisement

Receiving this error: The multi-part identifier “c.hrmort” could not be bound

All solutions point to the fact that if I’ve assigned aliases in my code, I should be using them instead of the table name itself. I have assigned alias and I AM trying to use the alias, however, I am still receiving this error.

Does this have to do with using an left join?

My code is as follows:

Advertisement

Answer

Your group by is outside of the subquery, so c.hrmort doesn’t exist. Instead group by x.MrtCategory and sum the amount outside of the subquery:

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