Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I'm trying to group my data, but I get "error in expression". This is what i'm writing:
any idea?
LOAD Temporada,
Semana,
Ejec.Comercial,
DetalleWeek,
[Estado Week],
NegocioWeek,
[N° Embarque],
[Est. Embarque (3D)],
[Est. Embarque (ERP)],
[Est. Doc. Embarque (ERP)],
FirstValue([Pallets Week]) as PalletWeek
FROM
GROUP BY DetalleWeek,NegocioWeek;
You have multiple non-aggregated fields in your load statement.... you will either need to add all of them to your group by or you need to remove them from your load statement. Essentially, based on your aggregation requirement, you need to have all your non-aggregating fields in your group by clause.
You have multiple non-aggregated fields in your load statement.... you will either need to add all of them to your group by or you need to remove them from your load statement. Essentially, based on your aggregation requirement, you need to have all your non-aggregating fields in your group by clause.
The GROUP BY load has very strict rules - you can only list fields that you are aggregating by, and aggregated values. In your example, you have 10 fields in the LOAD list, but only 2 fields in the GROUP BY list - that's not allowed. You can have either 2 fields in both lists, or 10 fields in both lists - in addition to your aggregations. FistValue() actually looks good, there shouldn't be any issues there.
cheers,
Oleg Troyansky
Upgrade Your Qlik Skills at the Masters Summit for Qlik - coming to Boston, MA this October!