<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Compare/Count a field in a datapil to other records in the same datapil without looping? in Workato Pros Discussion Board</title>
    <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7176#M3098</link>
    <description>&lt;P&gt;I have an Epicor BAQ report I use in Workato that gives me a list of all SKUs in an order and their shipping information&lt;/P&gt;&lt;P&gt;99.9% of the time all the SKUs in an order will be on the same pricebook but on rare occasions 2 SKUs might on pricebook X and 1 SKU on pricebook Y so each record in the BAQ report will have a pricebook field&amp;nbsp;&lt;/P&gt;&lt;P&gt;is there a way in workato to count the number of different prciebooks or do i have to loop through each record to count them?&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;</description>
    <pubDate>Mon, 29 Jul 2024 14:47:42 GMT</pubDate>
    <dc:creator>johnw</dc:creator>
    <dc:date>2024-07-29T14:47:42Z</dc:date>
    <item>
      <title>Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7176#M3098</link>
      <description>&lt;P&gt;I have an Epicor BAQ report I use in Workato that gives me a list of all SKUs in an order and their shipping information&lt;/P&gt;&lt;P&gt;99.9% of the time all the SKUs in an order will be on the same pricebook but on rare occasions 2 SKUs might on pricebook X and 1 SKU on pricebook Y so each record in the BAQ report will have a pricebook field&amp;nbsp;&lt;/P&gt;&lt;P&gt;is there a way in workato to count the number of different prciebooks or do i have to loop through each record to count them?&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jul 2024 14:47:42 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7176#M3098</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2024-07-29T14:47:42Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7177#M3099</link>
      <description>&lt;P&gt;I don't know how your data is structured, but you can use a combination of pluck and uniq to accomplish what you need.&lt;/P&gt;&lt;P&gt;Here's how they work:&lt;/P&gt;&lt;LI-CODE lang="ruby"&gt;list = [
    {"book": "a"},
    {"book": "a"},
    {"book": "b"}
]

books = list.pluck("book") 
## outputs ["a","a","b"]

uniqbooks = list.pluck("book").uniq 
## outputs ["a","b"]

uniqbooks.size 
## outputs 2, the number of items in the array
&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jul 2024 15:25:41 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7177#M3099</guid>
      <dc:creator>gary1</dc:creator>
      <dc:date>2024-07-29T15:25:41Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7179#M3101</link>
      <description>&lt;P&gt;this is cool... haven't played with Lists much in here.&lt;/P&gt;&lt;P&gt;So I created a List and loaded it with the field from the datapil which runs the BAQ report.&lt;/P&gt;&lt;P&gt;Do I need to create the list or is there a way to do these formulas directly from the data Pil; saving that one step?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;this works perfectly&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Pluck 1.png" style="width: 400px;"&gt;&lt;img src="https://systematic.workato.com/t5/image/serverpage/image-id/1463i6BC46873C2C4F707/image-size/medium/is-moderation-mode/true?v=v2&amp;amp;px=400" role="button" title="Pluck 1.png" alt="Pluck 1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;se list formulas directly from the BAQ step or if I have to convert to a list first&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="create list.png" style="width: 999px;"&gt;&lt;img src="https://systematic.workato.com/t5/image/serverpage/image-id/1462i8C933F5F7156390F/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="create list.png" alt="create list.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jul 2024 16:54:48 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7179#M3101</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2024-07-29T16:54:48Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7186#M3103</link>
      <description>&lt;P&gt;You can do it directly from the output of the Epicor action.&lt;/P&gt;&lt;P&gt;Also, just a heads up that will hopefully save you some time...&lt;/P&gt;&lt;P&gt;When you use .pluck you need to refer to a data pill by its "API key", which is the schema key and NOT it's readable label. This usually trips people up when using methods on connector data pills with really long labels, or when the label and the key are completely different.&lt;/P&gt;&lt;P&gt;To see the API key, just hover over the data pill. If you were to pluck the pill below, you would use .pluck("field_1") and not .pluck("blah blah blah...")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="api key.jpg" style="width: 576px;"&gt;&lt;img src="https://systematic.workato.com/t5/image/serverpage/image-id/1464iA71042F16973FEF8/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="api key.jpg" alt="api key.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I'm mentioning this because you might have to pluck "Price list 2 of price book ID 18 char c" and I would be very surprised if that label was also the API key.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jul 2024 17:06:23 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7186#M3103</guid>
      <dc:creator>gary1</dc:creator>
      <dc:date>2024-07-29T17:06:23Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7187#M3104</link>
      <description>&lt;P&gt;thanks, I was trying to use the output instead of the value which is why I couldn't get it to work &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;pretty cool&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jul 2024 17:50:30 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7187#M3104</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2024-07-29T17:50:30Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7273#M3145</link>
      <description>&lt;P&gt;this is working great but now I'm curios if there is a way to see if there are any blanks&lt;/P&gt;&lt;P&gt;if I do this and test&amp;nbsp; &amp;nbsp;[Value Step3}.pluck('PriceLstParts_SfPriceBookEntryId18Char_c')&lt;/P&gt;&lt;P&gt;I get a list of tehse fields such as&lt;/P&gt;&lt;P&gt;"A" "B" "C"&amp;nbsp;&lt;/P&gt;&lt;P&gt;but sometimes its&amp;nbsp;"A" "B"&amp;nbsp; "" "C"&amp;nbsp;&lt;/P&gt;&lt;P&gt;where one is blank I just want tos ee if Blanks are greater than 0&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;played around with scan and blank etc can't seem to get it to work&lt;/P&gt;&lt;P&gt;[Value Step3}.pluck('PriceLstParts_SfPriceBookEntryId18Char_c').blank?&lt;/P&gt;</description>
      <pubDate>Fri, 16 Aug 2024 23:48:16 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7273#M3145</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2024-08-16T23:48:16Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7277#M3146</link>
      <description>&lt;P&gt;It's not published in Workato, but "count" is a standard Ruby method that you can use.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="count.jpg" style="width: 684px;"&gt;&lt;img src="https://systematic.workato.com/t5/image/serverpage/image-id/1495i7EC66F01437C07A2/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="count.jpg" alt="count.jpg" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="count_output.jpg" style="width: 418px;"&gt;&lt;img src="https://systematic.workato.com/t5/image/serverpage/image-id/1496i7233FEB37766137C/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="count_output.jpg" alt="count_output.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://systematic.workato.com/t5/user/viewprofilepage/user-id/1695"&gt;@meghan-legaspi&lt;/a&gt;&amp;nbsp;Could someone add "count" to the formula helper and also to the Ruby docs?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.workato.com/developing-connectors/sdk/sdk-reference/ruby_methods.html" target="_blank"&gt;https://docs.workato.com/developing-connectors/sdk/sdk-reference/ruby_methods.html&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 17 Aug 2024 03:17:17 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7277#M3146</guid>
      <dc:creator>gary1</dc:creator>
      <dc:date>2024-08-17T03:17:17Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7290#M3157</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://systematic.workato.com/t5/user/viewprofilepage/user-id/1188"&gt;@gary1&lt;/a&gt;&amp;nbsp;– great thought! I can pass this along, though I also recommend submitting that feedback through the portal. Our team loves to keep in touch with the folks that make these requests to let them know when it's done! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 21 Aug 2024 20:08:14 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7290#M3157</guid>
      <dc:creator>meghan-legaspi</dc:creator>
      <dc:date>2024-08-21T20:08:14Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7293#M3159</link>
      <description>&lt;P&gt;Is the portal the one where users have to vote on which requests get prioritized?&lt;/P&gt;</description>
      <pubDate>Wed, 21 Aug 2024 22:59:36 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7293#M3159</guid>
      <dc:creator>gary1</dc:creator>
      <dc:date>2024-08-21T22:59:36Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7321#M3166</link>
      <description>&lt;P&gt;Hey Gary,&lt;/P&gt;
&lt;P&gt;You can submit feedback via AssistIQ when you are logged into your Workato account (see screenshot below). This should go straight to our support team – user voting shouldn't affect that.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-08-23 at 11.17.39 AM.png" style="width: 400px;"&gt;&lt;img src="https://systematic.workato.com/t5/image/serverpage/image-id/1511i7153A90DD50F41F9/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Screenshot 2024-08-23 at 11.17.39 AM.png" alt="Screenshot 2024-08-23 at 11.17.39 AM.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2024 15:19:06 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7321#M3166</guid>
      <dc:creator>meghan-legaspi</dc:creator>
      <dc:date>2024-08-23T15:19:06Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7785#M3289</link>
      <description>&lt;P&gt;how would pluck be used to see if there were any blank/empty fields?&lt;/P&gt;&lt;P&gt;was thinking something like this:&lt;/P&gt;&lt;P&gt;["value"].pluck('PriceLstParts_SfPriceBookEntryId18Char_c').count("") &amp;gt; 0&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 25 Sep 2024 11:05:18 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7785#M3289</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2024-09-25T11:05:18Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7799#M3297</link>
      <description>&lt;P&gt;When data is missing, it should be missing in a few different ways:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;The key is missing&lt;/LI&gt;&lt;LI&gt;The key is present and the value is ""&lt;/LI&gt;&lt;LI&gt;The key is present and value is null&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;If the key is always present and a blank value is "", then this will work!&lt;/P&gt;</description>
      <pubDate>Wed, 25 Sep 2024 23:54:51 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7799#M3297</guid>
      <dc:creator>gary1</dc:creator>
      <dc:date>2024-09-25T23:54:51Z</dc:date>
    </item>
    <item>
      <title>Re: Compare/Count a field in a datapil to other records in the same datapil without looping?</title>
      <link>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7804#M3300</link>
      <description>&lt;P&gt;got twisted around and needed to add a null option so this fixed my issue:&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;["value"].pluck('PriceLstParts_SfPriceBookEntryId18Char_c').count(null) &amp;gt; 0&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 26 Sep 2024 13:50:25 GMT</pubDate>
      <guid>https://systematic.workato.com/t5/workato-pros-discussion-board/compare-count-a-field-in-a-datapil-to-other-records-in-the-same/m-p/7804#M3300</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2024-09-26T13:50:25Z</dc:date>
    </item>
  </channel>
</rss>

