<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:clearspace="http://www.jivesoftware.com/xmlns/jive/rss" version="2.0">
  <channel>
    <title>Content in Tableau Community Forums</title>
    <link>/profile-content.jspa?filterID=contentstatus[published]&amp;targetUser=12049</link>
    <description>Recent content in Tableau Community Forums</description>
    <language>en</language>
    <pubDate>Wed, 15 May 2013 12:01:48 GMT</pubDate>
    <generator>Jive Engage 8.0.5.0  (http://jivesoftware.com/products/)</generator>
    <dc:date>2013-05-15T12:01:48Z</dc:date>
    <dc:language>en</dc:language>
    <item>
      <title>Simple query re: calculated fields that take into account date filters</title>
      <link>https://community.tableau.com/thread/126234</link>
      <description>&lt;!-- [DocumentBodyStart:16540938-fde6-4150-8f25-b54cc832e996] --&gt;&lt;div class="jive-rendered-content"&gt;&lt;p&gt;Hello,&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Would be very grateful if anyone could help me with the following.&amp;#160; I suspect there's a very simple solution but I've just not been able to get to it.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Summary:&amp;#160; Using Tableau 8.0.&amp;#160; Have two excel files linked together.&amp;#160; 1) Target.xls which shows a sales persons targets 2) Achievement.xls which shows a sales persons achievement&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;The target file contains the following fields...So far it has three months worth of Data - so the month can be April, May or June.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Salesperson:&amp;#160;&amp;#160; Mr Smith&lt;/p&gt;&lt;p&gt;Month: April &lt;/p&gt;&lt;p&gt;Product Name: Product XYZ&lt;/p&gt;&lt;p&gt;Target Value:&amp;#160; 5000 USD&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;The achievement file has a different field structure as it's pulled from a different database.&amp;#160; But the upshot is the Salesperson/Month/Product name fields are in common - so I link using those fields.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Now I've managed to link the files.&amp;#160; And I also am able to drag and drop my fields to get the tables I want - with the numbers correctly popluated.&amp;#160; So for example a table that looks like this&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;MONTH&amp;#160;&amp;#160; SALESPERSON PRODUCT NAME&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; TARGET&amp;#160;&amp;#160;&amp;#160; ACHIVEMENT&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; CALCULATED FIELD WANTED HERE&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;April 2013&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Mr Smith&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Product 1&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 5000 USD&amp;#160;&amp;#160;&amp;#160;&amp;#160; 8000 USD&lt;/p&gt;&lt;p&gt;April 2013&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Mr Smith&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Product 2&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 3000 USD&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 2000 USD&lt;/p&gt;&lt;p&gt;May 2013&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Mr Smith&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Product 1&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 3000 USD&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 1000 USD&lt;/p&gt;&lt;p&gt;May 2013&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Mr Smith&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Product 2&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 4000 USD&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 9000 USD&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Now here's where I get stuck.&amp;#160; I want to use a calculated field to add another column to the extreme right - which will&amp;#160; simply work out the target vs achievement percentage. &lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;In the calculated field I use the formula [ACHIEVEMENT]/[TARGET]&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Now this does give me some values in the table - but they are incorrect.&amp;#160; Comes out with strange percentages.&amp;#160; I think the reason is because the formula uses all the cumulative target values and the cumulative achievement values - i.e. it doesn't take into account my month column - and so not dividing the correct numbers. &lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;So how do I get the calculated formula to acknowledge the existence of the month column in the table - and give me the correct percentages accordingly?&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Any assistance would be much appreciated.&amp;#160; &lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Thanks in advance.&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:16540938-fde6-4150-8f25-b54cc832e996] --&gt;</description>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">dates</category>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">calculation</category>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">date</category>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">calculated</category>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">calculations</category>
      <pubDate>Wed, 15 May 2013 12:01:48 GMT</pubDate>
      <author>tableaucommunity@tableau.com</author>
      <guid>https://community.tableau.com/thread/126234</guid>
      <dc:date>2013-05-15T12:01:48Z</dc:date>
      <clearspace:dateToText>6 years 1 month ago</clearspace:dateToText>
      <clearspace:replyCount>1</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
    </item>
    <item>
      <title>Really simple division calculation via calculated fields - but it just won't work! Please help.</title>
      <link>https://community.tableau.com/thread/120611</link>
      <description>&lt;!-- [DocumentBodyStart:893bb1da-ada0-4036-92ca-14a861b0ce6c] --&gt;&lt;div class="jive-rendered-content"&gt;&lt;p&gt;Hello All,&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Tableau newbie here - love the product!&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;However having a bit of a strange problem with a really simple calculated field calculation - would appreciate any assistance.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;&lt;a href="https://community.tableau.com/servlet/JiveServlet/showImage/2-188414-3626/Picture+2.png"&gt;&lt;img alt="Picture 2.png" class="jive-image-thumbnail jive-image" height="113" onclick="" src="https://community.tableau.com/servlet/JiveServlet/downloadImage/2-188414-3626/450-113/Picture+2.png" style="" width="450"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;So data source is an excel file - and I used the fields of HQ Code, POB, PC and Date to construct the above table in the BI.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;HQ Code basically refers to a particular salesperson.&amp;#160; POB refers to the value of sales.&amp;#160; and PC refers to productive calls.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;So drag the relevant fields to make that table upto PC.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Then now that I have my monthly POB and monthly PC - what I wanted to work out was the average sale per call - for each of the months.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;In other words a calculated field formula of [POB]/[PC]&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;However as you'll see from the above .jpg - the number I get in the output is wrong.&amp;#160; So for example AP-01 has a July POB of 53,233.&amp;#160; And a July pob of 139.&amp;#160; So the figure should be 53233/129 = 382.&amp;#160; Instead I get this strange value of 7804 as you can see from the .jpg&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Here are things I've tried so far to get it to work.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;-Double checking that the raw data in excel is in "number" cell format.&lt;/p&gt;&lt;p&gt;-Noticed that the field was described as "float" in the calculated field bit.&amp;#160; So revised the formula to be integer instead i.e. something along the lines of (INT[POB)/(INT[PC])&amp;#160; or whatever.&amp;#160; The number changes slightly but completely the wrong order of magnitude.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Anyone able to help with what the formula should be? Dividing two numbers should be really easy - am confused. &lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Does this have anything to do with the monthly breakdown - i.e. calculated fields is not able to pick up the date field I've got going on in the table?&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Any assistance would be much appreciated.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Thanks in advance&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;-&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:893bb1da-ada0-4036-92ca-14a861b0ce6c] --&gt;</description>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">dates</category>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">calculated</category>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">fields</category>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">excel</category>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">dividing</category>
      <pubDate>Fri, 12 Oct 2012 17:29:07 GMT</pubDate>
      <author>tableaucommunity@tableau.com</author>
      <guid>https://community.tableau.com/thread/120611</guid>
      <dc:date>2012-10-12T17:29:07Z</dc:date>
      <clearspace:dateToText>6 years 8 months ago</clearspace:dateToText>
      <clearspace:replyCount>4</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
    </item>
  </channel>
</rss>

