Getting send indicator of delivery in a query | Community
Skip to main content
Level 3
Mar 10, 2022 2:45 PM UTC
Solved

Getting send indicator of delivery in a query

Hello all,

 

I want to get the number of send in a primary delivery in a query. I have selected as target "Delivery" and in "Additional data", if I choose "dynamicIndicators/@dynamicSent", I get the following:

Label                                           DynamicSent

[2022/03/03] Name delivery        12

[2022/03/04] Name delivery        7

 

What I want, it is the following

Label                        Sent

Name Delivery          19

 

I have tried choosing in "additional data", the following "[masterKpis/@sumSent]", but I get the following error:

PGS-220000 PostgreSQL error: ERROR: INSERT has more target columns than expressions LINE 1: ...INSERT INTO wkf114074112_70_1 (iMasterKpisSumSent,iId) SELEC...
 
Can someone help me?
 
Thanks in advance
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
JohnWi12Accepted solution
Level 5
Mar 10, 2022 3:30 PM UTC

The easy fix is to in you query select Primary = Yes.  That gives you an overall total for that delivery.  If you want a monthly total, you will need to change your recurring deliveries to aggregation period to a Month.  Your example indicates it is set to Day.  If you do the later then you can select only the current month totals by filtering the labels that have the current month and year.

7 replies

Sukrity_Wadhwa
Employee
Mar 24, 2022 4:57 AM UTC

Hi @lar1985,

Were you able to resolve this query with the help of the given solutions or do you still need more help here? Do let us know.
Thanks!

Translate
Sukrity Wadhwa
JohnWi12Accepted solution
Level 5
Mar 10, 2022 3:30 PM UTC

The easy fix is to in you query select Primary = Yes.  That gives you an overall total for that delivery.  If you want a monthly total, you will need to change your recurring deliveries to aggregation period to a Month.  Your example indicates it is set to Day.  If you do the later then you can select only the current month totals by filtering the labels that have the current month and year.

Translate
LAR1985Author
Level 3
Mar 10, 2022 4:42 PM UTC

Thanks @johnwi12 

 

I have tried including in the query, Primary= "Yes"

And in the output data I only get the proofs done:

 

Label                                           Send

[Proof 10] Name Delivery 1           4

[Proof 1] Name Delivery 2             1

 

Thanks

Translate
Level 5
Mar 10, 2022 7:02 PM UTC

Under properties, is the resource and targeting dimension Deliveries (Delivery)?

 

Add @2449631 in additional data.  Then run the query with the next step paused.  Click on the #record count, click open transition, then data.  You should see this: 

 

Translate