invalid reference to FROM-clause entry for table "unidades
snippet in sql

invalid reference to FROM-clause entry for table "unidades

user9803

remember to use the alias you used in from clause when using a column