How to use Attribute, Segment, Metric in Adwords Report

891 views
Skip to first unread message

naresh kumar

unread,
Jun 21, 2017, 10:43:23 AM6/21/17
to AdWords API Forum
Hi,

I am new to use this api.
I read about AWQL but to work with AWQL i need to understand how  Attribute Segment Metric works in report,
Any example you can give me here which clearly shows how to add  Attribute, Segment, Metric in AWQL ?

Here are the Attribute Segment Metric https://developers.google.com/adwords/api/docs/appendix/reports/account-performance-report

Thanks,
Naresh Kumar

Shwetha Vastrad (AdWords API Team)

unread,
Jun 21, 2017, 4:36:30 PM6/21/17
to AdWords API Forum
Hi Naresh, 

Please see this guide for the behavior of different types of fields in AdWords API reports. Fields of type "Attribute" contain settings or other fixed data and will always reflect the current state of the entities in your account. Fields of type "Metric" contain performance data for the DateRange specified in the report definition. Fields of type "Segment" are used to group metrics based on different dimensions. Please see this guide for more details on segmentation.

Regards,
Shwetha, AdWords API Team.

naresh kumar

unread,
Jun 22, 2017, 9:36:28 AM6/22/17
to AdWords API Forum
Hi There,

Thank you for your reply,
I am getting little about these terms ( Attribute, Segment, Metric in AWQL )

I tried to work with this in below example


$reportQuery
= "select
                                    AdNetworkType1,
                                    AdNetworkType2,
                                    ClickType,
                                    ConversionCategoryName,
                                    ConversionTrackerId,
                                    ConversionTypeName,
                                    Date
                                    from ACCOUNT_PERFORMANCE_REPORT during "
.$start_date.",".$end_date;
               
                $reportUtils
= new ReportUtils();
                $thi
= $reportUtils->DownloadReportWithAwql($reportQuery, $filePath, $user, $reportFormat = "CSV",$options);




In the above script i added "Segment" in Select Fields, and  Attribute  will come in Conditional part but what is the use of Metric and how can i implement.

More question:

Now i am getting report but in last of CSV report it is giving me " Total, --, --, --, --, --, -- " . What is this and how to get rid from this,

More if you can give me example of how i can use


Thanks,
Naresh Kumar

Shwetha Vastrad (AdWords API Team)

unread,
Jun 22, 2017, 2:39:39 PM6/22/17
to AdWords API Forum
Hi Naresh, 

You can include Metric fields to get performance data for your account over a time period. For example, If you include Impressions field in the report query, you'll get the number of impressions corresponding to that row. The last row in the report corresponds to the report summary which contains the report totals. Since this report query doesn't include any metric fields, these values are null. A sample response from the Campaign Performance Report is shown here.
Reply all
Reply to author
Forward
0 new messages