We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Adding summary of records in the Email Body

Alteryx_new
6 - Meteoroid

Hi,

 

I have developed a flow , which outputs the report to a excel table which is my first part.

 

then I want to create a summary of the report with start date range , end date range and count of the records and email it , which is the second part.

 

I was able to create start date range  and  end date range  in the second part.

 

Date Start

Date End

2023-05-01

2023-05-31

 

But I am struggling to add the count of the records in the second part like  below , is there a way?

 

Date StartDate EndNumber of Records
2023-05-012023-05-3110

 

Truly appreciate the help.

6 REPLIES 6
binuacs
21 - Polaris

@Alteryx_new would be able to provide some sample input files and expected output?

Alteryx_new
6 - Meteoroid

There are 2 inputs 

1) the output of the part 1 of the flow which is an excel file at the end in the attached flow ( yellow marked)

2) the dynamic dates created in the 2nd part of the file at the beginning (red marked) , the query used as below.

     select date_add('month', -1, date_add('day', -day(current_date)+1,current_date)) "Date Range Start",
    date_add('month', 0, date_add('day', -day(current_date),current_date)) "Date Range End"

 

The output is the email generated in the part 2 (blue marked) which should be the summary like below

 

Date Range StartDate Range EndNumber of Records
1/06/202330/06/202310

 

I was able to manage the  below

Date Range StartDate Range End
1/06/202330/06/2023

 

 

But I need number of records column as well.

Yoshiro_Fujimori
15 - Aurora
15 - Aurora

Hi @Alteryx_new ,

 

I guess you have a table to count the number of records in the specified date range.

If so, here is one way of doing this.

The idea is to append the date range to the table and filter the records with the date range.

I hope this helps.

 

Workflow

CompareDateRange_1.png

 

Alteryx_new
6 - Meteoroid

No, the date range are the parameters that are the beginning  and end of previous month.

the count is the number of records in the excel output.

 

and then summarize the data as below and send email.

 

Date Range StartDate Range EndNumber of Records
2023-06-012023-06-3010
Alteryx_new
6 - Meteoroid

Basically I want to include the number of records in the summary input (which is the input to the second part) , is there a way?

Yoshiro_Fujimori
15 - Aurora
15 - Aurora

@Alteryx_new 

Then you may try this.

1. Connect your sumary input table to Count Records tool to get a new column of number of records.

2. Add the new column to your summary input table with Append Field tool.

 

Labels
Top Solution Authors