List Info

Thread: addReportRequestWithAccountAggregation Returns variable XML attributes




addReportRequestWithAccountAggregation Returns variable XML attributes
user name
2006-12-04 18:49:21

Hey Don,

I'd suggest creating a list of all possible columns up front, as they
are documented in the Reports section of the online documentation. Then
just fill in blank/null values for the columns not present in a given
row. You should be able to generalizer this concept to work in all your
xml to tsv conversions.

Hope that helps,
-Y!SM Monkey

don.frazier wrote:
> Hello all ... I am submitting a
> addReportRequestWithAccountAggregation() for my account. In the
> returned XML, there seems to be quite a bit of variance on the
> reports, depending on the the data. In Adcenter and Adwords,
> every "row" in the XML report has the same "columns" regardless of
> the data.
>
> Panama seems to return different "rows" depending on the actual
> data. For example, the "analytics" element may contain the
> attributes numImpr, numClick, ctr, numConv, revenue, cost and
> averagePosition. But if ctr is anything other than "0.0", then the
> additional columns cpc, numConv, clickConvRate and roas are also
> present.
>
> My technique for parsing this report is to flatten it into a tab
> delimited file that I then bulk load into my data base for further
> processing. Obviously, the variable columns are killing my process.
> I'd like to keep my XML parser generic cuz it works basically the
> same for any XML data, as long as the data follows a set pattern.
> Any idea if there's a way to get a consistent set of columns in the
> output? Samples below.
>
>
> <row cmpgnID=&quot;92"; adGrpID=&quot;100&quot; keywordID="22&quot; urlID=&quot;48820&quot;
> accountName="xxx" accountID="30&quot; cmpgnName="s&quot; adGrpName="xx2&quot;
> keywordName="xx" url="http://xxx">
> <analytics numImpr=&quot;1" numClick=&quot;0"; ctr="0.0" numConv=&quot;0"
> revenue=&quot;0.0&quot; cost=";0.0" averagePosition=&quot;1.0" />
> </row&gt;
>
>
> <row cmpgnID=&quot;92"; adGrpID=&quot;100&quot; keywordID="222&quot; urlID=&quot;8"
> accountName="xxx" accountID="30&quot; cmpgnName="s&quot; adGrpName="xx&quot;
> keywordName="xx" url="http://xx">
> <analytics numImpr=&quot;26"; numClick=&quot;5"; ctr="0.19230769230769232&quot;
> cpc="0.11" numConv=&quot;0" clickConvRate="0.0" revenue=&quot;0.0&quot; roas=";0.0"
> cost=";0.55" averagePosition=&quot;1.1153846153846154&quot; />
> </row&gt;
>
>
>
>
>
> Yahoo! Groups Links
>;
>
>

__._,_.___
.

__,_._,___
addReportRequestWithAccountAggregation Returns variable XML attributes
user name
2006-12-05 17:02:27

Thank you monkey. Upon reviewing the documentation again, I see the
following: "KeywordSummary
A generated report that contains a pre-determined set of metrics for
each keyword.&quot;

This implies to me that the attributes, being "pre-determined&quot; are
not actually "pre-determined&quot; at all. The attributes that appear
are "determined"; based on others. For example, roas (and others)
only appear when numClicks is not 0.

After carefully scrutinizing the documentation, I don't see anywhere
that it mentions attributes being "optional" or "conditional&quot; or
anything else that indicates "sometimes here, sometimes not" nor any
mention of "when it's here and when it's not." That would be useful
documentation to have, up front, when I am developing custom code to
use the output. As it is, the sandbox never delivered variable
output so I incorrectly assumed the format was fixed. And as there
was no mention of variability in the output, I again only found the
problem once I had some live code to test.

Your suggestion is of limited value. I am trying to loosely couple
my parsing code to the reports (of which Yahoo/Panama is only 1).
You suggestion is I tightly couple my code to your format and create
a maintenance situation where I have to respond to every change in
the format with a corresponding change in code. In my solution, I am
loading the reports into a data base table and then normalizing it to
a format where I can do my own reporting. As it stands now, the only
thing I have to change when a report changes is the format of my bulk
load table. I like having a single change point rather than having
to re-compile, re-configure, etc.

My request is to deliver the reports as document, with the "pre-
determined" attributes. If there is no return, for example, just
include roas=";0.0". My solution was the reverse of your suggestion:
I included a list of columns that I could ignore if present. Not
good because I still have to update my config file if/when it
changes. But I can usually calculate the variable columns from other
sources.

Thank you for your time.

--- In yws-searchmarketing%40yahoogroups.com">yws-searchmarketingyahoogroups.com, "Yahoo! Search Marketing
Monkey&quot; <plummerm...> wrote:
&gt;
> Hey Don,
>
> I'd suggest creating a list of all possible columns up front, as
they
> are documented in the Reports section of the online documentation.
Then
> just fill in blank/null values for the columns not present in a
given
> row. You should be able to generalizer this concept to work in all
your
> xml to tsv conversions.
>
> Hope that helps,
&gt; -Y!SM Monkey
&gt;
> don.frazier wrote:
&gt; > Hello all ... I am submitting a
> > addReportRequestWithAccountAggregation() for my account. In the
> > returned XML, there seems to be quite a bit of variance on the
> > reports, depending on the the data. In Adcenter and Adwords,
> > every "row&quot; in the XML report has the same "columns" regardless
of
> > the data.
> >
> > Panama seems to return different "rows" depending on the actual
> > data. For example, the "analytics" element may contain the
> > attributes numImpr, numClick, ctr, numConv, revenue, cost and
> > averagePosition. But if ctr is anything other than "0.0&quot;, then
the
> > additional columns cpc, numConv, clickConvRate and roas are also
> > present.
> >
> > My technique for parsing this report is to flatten it into a tab
> > delimited file that I then bulk load into my data base for
further
> > processing. Obviously, the variable columns are killing my
process.
> > I'd like to keep my XML parser generic cuz it works basically the
> > same for any XML data, as long as the data follows a set
pattern.
> > Any idea if there's a way to get a consistent set of columns in
the
> > output? Samples below.
&gt; >
> >
> > <row cmpgnID=&quot;92"; adGrpID=&quot;100&quot; keywordID="22&quot; urlID=&quot;48820&quot;
> > accountName="xxx" accountID="30&quot; cmpgnName="s&quot; adGrpName="xx2&quot;
> > keywordName="xx" url="http://xxx">
> > <analytics numImpr=&quot;1" numClick=&quot;0"; ctr="0.0" numConv=&quot;0"
> > revenue=&quot;0.0&quot; cost=";0.0" averagePosition=&quot;1.0" />
> > </row&gt;
> >
> >
> > <row cmpgnID=&quot;92"; adGrpID=&quot;100&quot; keywordID="222&quot; urlID=&quot;8"
> > accountName="xxx" accountID="30&quot; cmpgnName="s&quot; adGrpName="xx&quot;
> > keywordName="xx" url="http://xx">
> > <analytics numImpr=&quot;26"; numClick=&quot;5"; ctr="0.19230769230769232&quot;
> > cpc="0.11" numConv=&quot;0" clickConvRate="0.0" revenue=&quot;0.0&quot;
roas=&quot;0.0";
> > cost=";0.55" averagePosition=&quot;1.1153846153846154&quot; />
> > </row&gt;
> >
> >
> >
> >
> >
> > Yahoo! Groups Links
>; >
> >
> >
>

__._,_.___
.

__,_._,___
[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )