Aggregates on data of filtering dimension | Community
Skip to main content
Marcel_Szimonisz
New Participant
June 27, 2019
Solved

Aggregates on data of filtering dimension

  • June 27, 2019
  • 12 replies
  • 10556 views

Hello All,

Before there was a checkbox where you could exclude id from the main set when doing aggregate functions. Now that is gone you always get error saying

enrich WDB-200001 SQL statement 'INSERT INTO wkf631156212_14_1 (sBrowserName,iMax__id_,iCount__id_,iId) SELECT   U2.sBrowserName, max(W0.iId), Count(W0.iId), W0.iId FROM wkf631156212_13_1 W0 JOIN NmsTrackingLogRcp T1 ON (T1.iTrackingLogId = W0.iId) JOIN NmsUserAgent U2 ON (U2.iHashKey = T1.iUserAgent) WHERE ((T1.iTrackingLogId > 0 OR T1.iTrackingLogId < 0)) GROUP BY U2.sBrowserName' could not be executed.

enrich PGS-220000 PostgreSQL error: ERROR:  column "w0.iid" must appear in the GROUP BY clause or be used in an aggregate function LINE 1: ...422,iId) SELECT   U2.sBrowserName, count(W0.iId), W0.iId FRO...

                                                     

It always add the primary key to the aggregate function how i am supposed to do the queries now. Do you guys have workaround other than select all and then do the aggregates linked to the dimension?

thanks

marcel

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by asariaaara

Hi marcel.gent.86​,
That excluding PK option is not found in enrichment from as long i am using ACM.
However you can use query to group/aggregate the data, excluding automatic adding of PK can be found there.

Regards.

12 replies

Marcel_Szimonisz
New Participant
June 28, 2019

Hello Jon,

that is what I say they removed it from there. Below you can see what we can select now. its either moved or it was removed.

summoning the elders Amit_Kumar​,florentlbfloriancourgeydavid_garciaJean-Serge Biron​ for their kind feedback

Marcel

Jonathon_wodnicki
New Participant
June 27, 2019

Hi,

Click 'Advanced parameters...' under 'Edit additional data...' dialog and check 'Disable automatic adding of the primary keys to the targeting dimension'.

Thanks,

-Jon