<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Anggi Firdian Saputra on Medium]]></title>
        <description><![CDATA[Stories by Anggi Firdian Saputra on Medium]]></description>
        <link>https://medium.com/@afer.sptr?source=rss-1613b3c71e1e------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*i5JDk5JOmMb79YHZ5wC-AA.jpeg</url>
            <title>Stories by Anggi Firdian Saputra on Medium</title>
            <link>https://medium.com/@afer.sptr?source=rss-1613b3c71e1e------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 06 Dec 2026 02:34:30 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@afer.sptr/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Get to Know About Pivot Table Pt. 5]]></title>
            <link>https://medium.com/@afer.sptr/get-to-know-about-pivot-table-pt-5-51b9f5d827af?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/51b9f5d827af</guid>
            <category><![CDATA[getpivotdata]]></category>
            <category><![CDATA[drilling-down]]></category>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[pivottable-wizard]]></category>
            <category><![CDATA[pivot-tables]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Fri, 27 Jan 2023 03:47:13 GMT</pubDate>
            <atom:updated>2023-01-27T03:48:30.744Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Cva4kybSEmHIM9Dpw-6XUQ.jpeg" /></figure><h4>Drilling Down, GETPIVOTDATA, Timeline, and PivotTable and PivotChart Wizard</h4><p>Sometimes, PivotTables will make it difficult for us when we want to add a new PivotTable, and if we only add PivotTables manually on the same sheet, changes to existing data in the second PivotTable will affect the first PivotTable. This will make it difficult for us if there is a lot of data that we want to change and compare on the same sheet. Therefore, in this discussion, we will discuss about <strong>Drilling Down, GETPIVOTDATA, Timeline, and PivotTable and PivotChart Wizard </strong>which help us to analyze more easily.</p><h4><strong>Drilling Down</strong></h4><p>When we double-click a cell in a PivotTable, Excel displays all the detailed data that’s summarized in that field in a separate worksheet. This is called <em>drilling down</em>. For example, when we double click on the Bitcoin data in the month column, we will see a dialog box display from Drilling Down listing detailed information from the Month Field. If we select one in the drilling down dialog box, we will see detailed data from the Month Field summary.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/355/1*KB1raBLm8YK8e5k8LhgQdQ.png" /><figcaption><strong>Summary of Bitcoin Data</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/543/1*sfjbDpGastpYd-FL3y0vxA.png" /><figcaption><strong>Dialog Box of Drilling Down Month Column</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/1*lgmrzKNjFQ0hagNGIPjKdQ.png" /><figcaption><strong>Detail Information from Drilling Down Month Column</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Jsb0BrWOIRUiPc_rQNjEbQ.png" /><figcaption><strong>Summary of Bitcoin Data and Original Table of Bitcoin Data (Sheet 1)</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/490/1*v_31qoLUBMB2A51r6C2JMQ.png" /><figcaption><strong>Result of Drilling Down Return Column (Display in New Sheet 6)</strong></figcaption></figure><h4>GETPIVOTDATA</h4><p>To see the results of calculations in the PivotTable, we sometimes use general formulas for calculations in Excel, but if the data in the PivotTable is added, then the results of the calculations that we have written will move around. So, to ensure that the results displayed from the formula we write do not change, we can use the <em>GETPIVOTDATA</em> formula to retrieve data directly from the PivotTable without moving around the data when a field column changes.</p><p>Here is an example:</p><pre>##Get the Sum of Revenue during April in France and the Product is Chip 1<br>=GETPIVOTDATA(&quot;Sum of Revenue&quot;;$A$3;&quot;Month&quot;;&quot;April&quot;;&quot;Product&quot;;&quot;Chip 1&quot;;&quot;Country&quot;;&quot;France&quot;)<br><br>##Get Grand Total of Sum of Revenue Field<br>=GETPIVOTDATA(A4;&quot;Sum of Revenue&quot;)</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cSLh1yyzlm4Pdy9rEeOaYw.png" /><figcaption><strong>PivotTable of Sales Chip Data</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CTv9gfmXy_v2IZTq_HI19Q.png" /><figcaption><strong>Result of GETPIVOTDATA Formula</strong></figcaption></figure><p>Often, the <em>GETPIVOTDATA</em> function is a nuisance. For example, suppose we want to refer to data in cells <strong>B5:B10</strong> from a PivotTable elsewhere in our workbook. We would probably use the formula <strong>=B5</strong> and copy it to the range <strong>B6:B10</strong>. We expect this action to extract <strong>B6, B7, ,…, B10</strong> to the cells we want. Unfortunately, if the <em>GETPIVOTDATA</em> option is active, we instead get a bunch of <em>GETPIVOTDATA</em> functions that refer to the same cell. Fortunately, we can turn off <em>GETPIVOTDATA</em>. Follow these steps:</p><ul><li>Click the <strong>File tab</strong> and click<strong> Options</strong></li><li>In the left pane of the <strong>Excel Options dialog box</strong>, click <strong>Formulas</strong></li><li>In the right pane, under <strong>Working with Formulas, deselect the Use GetPivotData Functions for PivotTable References check box</strong>. Then click <strong>OK.</strong></li></ul><p>We can also turn off <em>GETPIVOTDATA</em> in a particular PivotTable. Here is how:</p><ul><li>Click in the <strong>PivotTable</strong></li><li>In the <strong>PivotTable group</strong> on the<strong> PivotTable Analyze tab</strong>, <strong>click the arrow next to the Options button and deselect the Generate GetPivotData check box in the menu that appears.</strong></li></ul><p>Now, if we simply type <strong>=B5 </strong>in a cell <strong>instead of entering =B5 by pointing,</strong> we can <strong>just drag down the =B5 formula</strong>, and <em>GETPIVOTDATA</em> would not be relevant.</p><h4>TIMELINE</h4><p>If we work with sales data, surely we find a date to see what date the transaction was made. To make it easier for us to see all transactions by date, we need adjustable filters so that the data displayed in the <strong>PivotTable</strong> matches what we want to see. Therefore, we need the <strong>Timeline filter</strong> to do this.</p><p>To apply the Timeline feature, follow these steps:</p><ul><li>Click anywhere in the <strong>PivotTable</strong></li><li>In the <strong>Filters group</strong> on the <strong>Insert tab</strong>, click the <strong>Timeline</strong> button</li><li>In the <strong>Insert Timelines dialog box</strong>, select <strong>Date</strong> and click <strong>OK</strong>. We will see the timeline as follows:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eSqxqy5HgVgqGg-2DWq4NQ.png" /><figcaption><strong>Timeline Filter</strong></figcaption></figure><p>In the<strong> Month</strong> in the <strong>Timeline box</strong>, we can change it to <strong>Years, Quarters, or Days.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/616/1*eOld0XdG90YvXobQCnh35w.png" /><figcaption><strong>List Filter on Timeline Filter</strong></figcaption></figure><h4>PivotTable and PivotChart Wizard</h4><p>As we know, there are data sources from companies from various sources because the data does not come from just one division in the company, but from several divisions that collect data on their own. Therefore, we need a <strong>PivotTable and PivotChart Wizard </strong>to combine data from different Excels.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SulMC04kaR10b9E7BdzZ_w.png" /><figcaption><strong>East Sales Data (Left), West Sales Data (Right)</strong></figcaption></figure><p>To produce a <strong>PivotTable</strong> that summarizes the total sales of each product during each month, here is the steps:</p><ul><li>Press <strong>Alt+D+P</strong> to open the <strong>PivotTable And PivotChart Wizard</strong></li><li>Select <strong>Multiple Consolidation Ranges</strong> and click <strong>Next.</strong> If we choose <strong>Another PivotTable report or PivotChart report</strong>, <strong>this is only to add a new PivotTable in a place where there is also a PivotTable</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/649/1*prC6uojF6ZrwETVJnh42Sg.png" /><figcaption><strong>PivotTable and PivotChart Dialog Box</strong></figcaption></figure><ul><li>Choose <strong>Create a Single Page Field for Me</strong> and click <strong>Next</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/679/1*xfRpYisFQOsbeevCKN7glw.png" /></figure><ul><li>In the <strong>Range box</strong>, select the <strong>East sales data (EAST!$A$1:$D$18)</strong> and click <strong>Add to add it to the All Ranges box</strong></li><li>Clear the <strong>Range box</strong>. Then select the <strong>West sales data (WEST!$A$1:$D$24)</strong> and click <strong>Add to add it to the All Ranges box</strong>. Then click <strong>Next. Note:</strong> To create a PivotTable from multiple ranges using the wizard, <strong>the headings</strong> (in this case January, February, and March) in each range <strong>must be identical</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/870/1*ucoCk4--Gxj7vaBaEYJlnQ.png" /><figcaption><strong>Consolidate Dialog Box of PivotTable and PivotChart Wizard</strong></figcaption></figure><ul><li>Specify that we want to place the final <strong>PivotTable </strong>in a new worksheet and click <strong>Finish.</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/847/1*HW54fpRZjyq6RHGDhjiUHQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XbQZKH6E1LOekhsd7UjLXA.png" /><figcaption><strong>Result of PivotTable and PivotChart Wizard</strong></figcaption></figure><p>Finally, the discussion about <strong>PivotTables</strong> has ended here. I look forward to your suggestions and comments. Thank you 😜 😆</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=51b9f5d827af" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Get to Know About Pivot Table Pt.4]]></title>
            <link>https://medium.com/@afer.sptr/get-to-know-about-pivot-table-pt-4-eb9a98fb6dd8?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/eb9a98fb6dd8</guid>
            <category><![CDATA[pivot-tables]]></category>
            <category><![CDATA[calculated-field]]></category>
            <category><![CDATA[value-field-setting]]></category>
            <category><![CDATA[calculated-item]]></category>
            <category><![CDATA[excel]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Thu, 26 Jan 2023 15:52:33 GMT</pubDate>
            <atom:updated>2023-01-26T15:52:33.914Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/925/1*NlUKq7Q0lc4f9DONXb1i5A.png" /></figure><h4>Grouping, Calculated Field/Items, and Value Field Setting</h4><p>Calculations and grouping are very important for us in analyzing and making a report from the data that we have processed. Often we encounter a large number of numerics, dates, and text as the subject of existing data. However, it is very confusing for us to make a conclusion from the insight data we get. Therefore, in this discussion, we will discuss <strong>Grouping, Calculated Field/Items, and Value Field Settings</strong> to perform simple statistical calculations.</p><h4>Grouping Field</h4><p>To group data, there are two ways to group data, the first can be done directly by <strong>clicking Group selection</strong> on the <strong>Group ribbon</strong> on the <strong>PivotTable Analyze tab</strong>, <strong>usually this method is used for data in the form of numeric and date,</strong> the second can be by <strong>first filtering the data that we want to group them</strong>, then group them by clicking <strong>Group selection </strong>on the <strong>Group ribbon on the PivotTable Analyze tab</strong>, <strong>usually this method is used for data in the form of text.</strong></p><p><strong>Grouping data in form of numeric and dates:</strong></p><ul><li>Place the cursor anywhere on the <strong>PivotTable</strong></li><li>Right click, then a dialog box will appear from row labels, then select <strong>Group</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/403/1*t0OGKoFSUa-L6bENDAnhSQ.png" /></figure><ul><li>The <strong>Grouping dialog box</strong> will appear, then we can set the data we want to group and we have to set the grouping interval. On this occasion, we will set the <strong>interval to 10.</strong> Then click <strong>OK</strong>.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/384/1*2akUQGO_BQmN2dy3UVxkkw.png" /><figcaption><strong>Table of Numeric Data</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/711/1*e35Zpy_XAI919jNUa81DOw.png" /><figcaption><strong>Numeric Grouping Dialog Box</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/397/1*P8_VeYPck1wY5zLOgqpXXg.png" /><figcaption><strong>Result of Nurmeric Grouping</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/277/1*uXZUZAvAzP6EBLr1-Kfcow.png" /><figcaption><strong>Table of Date Data</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/390/1*8iCexfKOprw-Rb_fhRQo5g.png" /><figcaption><strong>Grouping Dialog Box for Date Data</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/286/1*UeH2YZ764zsJ5gCbhvN_MQ.png" /><figcaption><strong>Result of Grouping Date Data</strong></figcaption></figure><p><strong>Grouping data in form of text:</strong></p><ul><li>Click <strong>Filter </strong>on the <strong>Row Labels</strong> in the <strong>PivotTable</strong></li><li>Searching data that we want to filter to the group</li><li>Then, the block all data that we want to group. After that, click <strong>Group Selection </strong>on the <strong>Group ribbon</strong> in the <strong>PivotTable Analyze tab</strong></li><li>Follow the second to third steps for the second data that we want to group. Then, rename the data that we have grouped. And finished</li><li>A new field will appear in the PivotTable Field List, and we can set this to display or not the data that we have grouped.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/235/1*_Cj4Y7sl5VfDktg6XDt6Uw.png" /><figcaption><strong>Table of Text Data Type</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/526/1*geqA0O8I85X3jlHs8YQ-zA.png" /><figcaption><strong>New Field Appear in the Field List</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/229/1*SQGbt91v8VD182rdpVfM1A.png" /><figcaption><strong>Result of Grouping Text Data Type</strong></figcaption></figure><h4>Calculated Field/Items</h4><p>In a calculated field, we can only perform calculations for the field, not for specific items in the PivotTable. As for calculated items, we can calculate and group an item and calculate it into units.</p><p>Here are the steps to perform a Calculated Field:</p><ul><li>Place the cursor anywhere on the <strong>PivotTable</strong></li><li>Click <strong>Calculated Field</strong> on the <strong>Calculations ribbon</strong> on the <strong>PivotTable Analyze tab</strong></li><li>In the <strong>Field column,</strong> we can provide the name of the formula that we will write. Whereas in the <strong>Formula column</strong>, we can write any formula related to the<strong> Field</strong> in the <strong>Field List</strong>. After that,<strong> click Add and then click OK.</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*YxaB_SU40xKoioHohHjmPg.png" /><figcaption><strong>Dialog Box of Calculated Field</strong></figcaption></figure><p>Here are the steps to perform a Calculated Items:</p><ul><li>Place the cursor on the data item for which we want to perform calculations. Here is an example:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/277/1*kxV62R_YoGnXVaz6b5K2MA.png" /><figcaption><strong>Table of Brand and Sales</strong></figcaption></figure><ul><li>Click <strong>Calculated Item </strong>on the <strong>Calculations ribbon</strong> on the <strong>PivotTable Analyze tab</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/387/1*8iMLSk_J5bfxTbguWq1C_A.png" /><figcaption><strong>Calculations Ribbon</strong></figcaption></figure><ul><li>In the <strong>Field column,</strong> we can provide the name of the formula that we will write. Whereas in the <strong>Formula column</strong>, we can write any formula related to the<strong> Item </strong>in the <strong>Items List</strong>. After that,<strong> click Add and then click OK. </strong>Here is an example:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/745/1*aKFe-0HY7PucYkUnv0vFCA.png" /><figcaption><strong>Dialog Box of Calculated Item</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/268/1*rKMxiWTQyKCfg2W-DiUi7w.png" /><figcaption><strong>Result of Calculated Item of Japan</strong></figcaption></figure><h4>Value Field Setting</h4><p>To do a simple statistical summary, we can use the <strong>Value Field Setting</strong> option in the <strong>Values ​​Fields List.</strong> Here are the steps:</p><ul><li>Right click on the <strong>Value Field</strong> in the <strong>PivotTable</strong>. Then, select <strong>Value Field Settings</strong></li><li>We can choose statistical values ​​to be used in the <strong>Value Field</strong> from <strong>SUM to VARP</strong>. After selecting, click <strong>OK</strong></li><li>If we want something other than the statistics in the list, then we can click <strong>Show Values ​​As</strong>. In the<strong> Show Values ​​As dialog box</strong>, we can choose calculations <strong>starting from the % of Grand Total to the Index of the Value Field itself.</strong> An explanation of each choice, both in simple statistics and the Show Values ​​As option, will be explained below.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/565/1*zKYrcCwMcBXb0_sSkbYJrw.png" /><figcaption><strong>Summarize Value Field By Dialog Box</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/565/1*ndRIvXjY6SkCZKdfx3KyZg.png" /><figcaption><strong>Show Values As Dialog Box</strong></figcaption></figure><p>To calculate a value field, the following summary functions are available for all source data types except Online Analytical Processing (OLAP) source data:</p><ul><li><strong>SUM: </strong>Sum of values. This function is the default function for numeric data</li><li><strong>COUNT: </strong>Sum of data values. The Count summary function works like the COUNTA function. Count is the default function for data other than numbers</li><li><strong>AVERAGE:</strong> Average value</li><li><strong>MAX:</strong> Greatest value</li><li><strong>MIN:</strong> Smallest value</li><li><strong>PRODUCT:</strong> The product of values</li><li><strong>COUNT NUMS:</strong> The number of data values ​​in the form of numbers. The Count Nums summary function works the same as the COUNT Function</li><li><strong>StDev:</strong> An estimate of the population standard deviation, where the sample is a subset of the entire population</li><li><strong>StDevp:</strong> The population standard deviation, where the population exists is all the data that is summarized</li><li><strong>VAR:</strong> Estimates of population variance, where the sample is a subset of the entire population</li><li><strong>VARP:</strong> The variance of the population, where the population is all the summarized data</li></ul><p>Custom calculations show values ​​based on other items or cells in the data area. The following functions are available for custom calculations in value fields (<strong>Show Values As</strong>):</p><ul><li><strong>No Calculation:</strong> Displays the value entered in the field</li><li><strong>% of Grand Total:</strong> Displays values ​​as a percentage of the grand total of all values ​​or data points in the report</li><li><strong>% of Column Total:</strong> Displays all values ​​in each column or series as a percentage of the total for that column or series</li><li><strong>% of Row Total:</strong> Displays the value in each row or category as a percentage of the total for that row or category</li><li><strong>% Of:</strong> Displays value as a percentage of the <strong>base Item value</strong> in <strong>Base field</strong></li><li><strong>% of Parent Row Total: </strong>Calculates the value as follows: <strong>(value for item)/(value for parent item in row)</strong></li><li><strong>% of Parent Column Total:</strong> Calculates the value as follows: <strong>(value for item)/(value for parent item in column)</strong></li><li><strong>% of Parent Total: </strong>Calculates the value as follows:<strong> (value for item)/(value for parent item of selected base Field)</strong></li><li><strong>Difference From:</strong> Returns the value as the difference from the <strong>base Item value </strong>in the <strong>Base field</strong></li><li><strong>% Difference From: </strong>Displays the value as a percentage difference from the<strong> base Item value</strong> in<strong> Base field</strong></li><li><strong>Running Total In: </strong>Displays the value for <strong>sequential items</strong> in the <strong>Base field</strong> as a provisional total</li><li><strong>% Running Total In: </strong>Calculates the value for <strong>sequential items</strong> in the <strong>Base field </strong>shown as a provisional total as a percentage</li><li><strong>Rank Smallest to Largest: </strong>Returns the ranking of the selected value in a given field, <strong>lists the smallest item in the field as 1</strong>, and any value that is <strong>greater has a higher ranking value</strong></li><li><strong>Rank Largest to Smallest:</strong> Displays the rank of the selected value in a given field, <strong>lists the largest item in the field as 1</strong>, and any <strong>lower value has a higher ranking value</strong></li><li><strong>Index:</strong> Calculates the value as follows: <strong>((value in cell) x (Grand Total Grand Total))/((Grand Row Total) x (Grand Column Total))</strong></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eb9a98fb6dd8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Get to Know About Pivot Table Pt.3]]></title>
            <link>https://medium.com/@afer.sptr/get-to-know-about-pivot-table-pt-3-da8ecdcd6285?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/da8ecdcd6285</guid>
            <category><![CDATA[update-pivot-table]]></category>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[slicer-pivot-table]]></category>
            <category><![CDATA[layout-pivot-table]]></category>
            <category><![CDATA[pivot-tables]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Thu, 26 Jan 2023 00:14:16 GMT</pubDate>
            <atom:updated>2023-01-26T00:14:16.289Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/331/1*v_DkRtxReXa1sxbdyJCTHw.png" /></figure><h4>Slicer, Layout, and Update PivotTable</h4><p>In this discussion, we will discuss modifying a PivotTable to make it easier to read or for other purposes. We will use the ribbon layout in the design menu of the PivotTable and the slicer in the ribbon filter in the menu of the PivotTable Analyze.</p><h4>PivotTable Slicer</h4><p>Slicers are used to make it easier for us to view certain specific data, where we can set the contents of the PivotTable which is presented in the form of a menu in the slicer. This makes it easier for us to filter any data that we want to display.</p><p>To make a slicer, here are the steps:</p><ul><li>Place our cursor anywhere in the <strong>PivotTable</strong></li><li>In the <strong>Filters group</strong> on the <strong>Insert tab</strong>, click the <strong>Slicer</strong> button</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*J5eHX93QYqb5fpgeCWoc4A.png" /><figcaption><strong>Filter Ribbon in the Menu Insert</strong></figcaption></figure><ul><li>In the <strong>Insert Slicers dialog box</strong>, select the data that we want to filter and to display, then click <strong>OK</strong>.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*4bWQnxMGcKoKPyC-b3LlkQ.png" /><figcaption><strong>Slicer Dialog Box</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/454/1*LTbZJADZ8Bq89eXOBop75A.png" /><figcaption><strong>Display Slicer</strong></figcaption></figure><p>We can change the appearance of the slicer window as well as how slicers are displayed within the window.</p><p>We can also arrange the slicers in columns and change other settings. To do so, <strong>right click </strong>any slicer in the window and choose <strong>Size and Properties</strong> in the menu that appears. The Format Slicer pane opens, we can make our changes from here. (<strong>We might need to click the arrow next to the Position and Layout, Size, or Properties headings to view the settings we want</strong>).</p><h4>Layout in a PivotTable</h4><p>On this ribbon layout, we can add blank rows, hide subtotals, or modify empty cells in a PivotTable.</p><p><strong>To add a blank row between each grouped item</strong>, here are the steps:</p><ul><li>Click a cell in the <strong>PivotTable</strong></li><li>Then, in the <strong>Layout group</strong> of the <strong>Design tab</strong>, click <strong>Blank Rows</strong> and choose <strong>Insert Blank Line After Each Item. </strong>If we want to<strong> delete these blank rows</strong>, we can choose the option in the <strong>Blank Rows dialog box</strong> as <strong>Remove Blank Line after Each Item.</strong></li></ul><p><strong>If we want to hide subtotals or grand totals</strong>, here are the steps:</p><ul><li>Click a cell in the <strong>PivotTable</strong></li><li>Then, in the <strong>Layout group</strong> of the <strong>Design tab</strong>, click <strong>Subtotals</strong> and choose <strong>Do Not Show Subtotals</strong>. <strong>Alternatively,</strong> click the <strong>Grand Totals </strong>button and choose <strong>Off For Rows and Columns.</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/675/1*2s48xwf0mWz-T3g4--CA_Q.png" /><figcaption><strong>Before Add Blank Rows and Hide Subtotals</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/673/1*rjkuZTKVGWgmWWtpC9f5Hg.png" /><figcaption><strong>After Add Blank Rows and Hide Subtotals</strong></figcaption></figure><p><strong>To fill empty cells </strong>with a character such as an underscore or a zero, follow these steps:</p><ul><li>Right-click any <strong>PivotTable </strong>cell and choose <strong>PivotTable Options</strong></li><li>The <strong>PivotTable Options </strong>dialog box opens</li><li>In the <strong>Format </strong>section of the <strong>Layout &amp; Format tab</strong>, enter the character we want to use in the<strong> For Empty Cells Show box</strong>. Then click <strong>OK</strong>.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/652/1*Nr7X9aRtEfViUEll1CPbtg.png" /><figcaption><strong>PivotTable Options Dialog Box</strong></figcaption></figure><h4>Update PivotTable</h4><p>If the data in our original set of rows changes, we can update our <strong>PivotTable </strong>to include those changes by <strong>right-clicking the table and selecting Refresh</strong>. Alternatively, we can <strong>click the Refresh button in the Data group on the PivotTable Analyze tab.</strong></p><p><strong>Note: </strong>If we want data that we add to be automatically included in our <strong>PivotTable</strong> calculations when we refresh it, we should <strong>convert our original data set to a table</strong>. To do so, <strong>select the data set and press Ctrl+T</strong>.</p><p>Suppose we want to change the range of data used to create a <strong>PivotTable</strong>. In that case, we can select <strong>Change Data Source</strong> in the<strong> Data group</strong> on the <strong>PivotTable Analyze tab</strong>. <strong>We can also move the table to a different location by clicking Move PivotTable in the PivotTable Analyze tab’s Actions group.</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=da8ecdcd6285" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Get to Know About Pivot Table Pt.2]]></title>
            <link>https://medium.com/@afer.sptr/get-to-know-about-pivot-table-pt-2-53b33379846d?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/53b33379846d</guid>
            <category><![CDATA[pivot-chart]]></category>
            <category><![CDATA[sort-and-filter]]></category>
            <category><![CDATA[data-analysis]]></category>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[excel-pivot-tables]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Wed, 25 Jan 2023 15:54:04 GMT</pubDate>
            <atom:updated>2023-01-25T15:54:04.490Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/247/1*gHgMCnZMSEooYVMEmE9XAg.png" /></figure><h4>Sorting, Filtering, and creating PivotCharts</h4><p>In the previous discussion we have discussed the introduction of PivotTables, Layouts, Collapse, and Expand PivotTables. In this discussion, we will discuss Sorting, Filtering, and creating PivotCharts in PivotTables.</p><h4>Sort PivotTable Fields</h4><p>The following are the steps for sorting a PivotTable:</p><ul><li>Move the cursor to any cell that we want to do sort</li><li>Then click the <strong>Row Labels </strong>arrow in cell that we want to do sort, and choose <strong>Sort Z to A </strong>from the list of options that appears to sort the data based on descending, while <strong>Sort A to Z </strong>to sort the data based on ascending</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/430/1*y8AOWBOg9vuRuWZdbFXaCQ.png" /><figcaption><strong>Row Labels Dialog Box</strong></figcaption></figure><h4>Filter PivotTable Fields</h4><p>Suppose we want to filter the data to see a list of our top 10 customers. Here’s how we might do this:</p><ul><li>Click the <strong>Row Labels</strong> arrow, choose<strong> Value Filters</strong>, and <strong>select Top 10. </strong>Verify that <strong>Top 10 Items </strong>is selected, then click<strong> OK. Note: </strong>in the dialog box of Top 10 Items, we can select <strong>Top/Bottom</strong>, adjust the value that we want, and change the result to be displayed as <strong>item/percent/sum</strong>.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/694/1*4eV26iy-pnJ542Rk_2dFaw.png" /><figcaption><strong>Value Filter Dialog Box</strong></figcaption></figure><ul><li>To return to the original layout, click the <strong>Row Labels </strong>arrow and select <strong>Clear Filter.</strong></li></ul><h4>Create PivotChart to Summarize a PivotTable</h4><p>Suppose we want to summarize the trend over time of each food group’s unit sales. Here’s how:</p><ul><li>Click anywhere inside the <strong>PivotTable</strong>. Then, in the <strong>Tools group</strong> on the <strong>PivotTable Analyze tab</strong>, click <strong>PivotChart</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/838/1*T1PiVizfjVzBl7MqCBmFqg.png" /><figcaption><strong>PivotChart Box</strong></figcaption></figure><ul><li>In the <strong>Insert Chart dialog box</strong>, pick the chart type we want to create. We chose the first line graph option</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/706/1*r_-Z8QciF_PCWPHJ3XBJhg.png" /><figcaption><strong>Graph of Time of Each Food Group’s Unit Sales</strong></figcaption></figure><p>This chart indicates that <strong>milk sales were highest in 2005 and lowest in 2006.</strong></p><p><strong>Note:</strong> If we look at the graph above, <strong>there are arrows for each description which are gray in color</strong>. We can do<strong> filtering and sorting</strong> directly on the graph and it will be displayed directly on the graph. In addition, we can see <strong>in the lower right corner, there are positive (+) and negative (-) signs,</strong> these signs make it easier for us <strong>to collapse or expand t</strong>he PivotTable data, where the results of the collapse or expansion will be immediately displayed on the graph.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=53b33379846d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Get to Know About Pivot Table Pt.1]]></title>
            <link>https://medium.com/@afer.sptr/get-to-know-about-pivot-table-ee62a84a8624?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/ee62a84a8624</guid>
            <category><![CDATA[collapse-and-expand]]></category>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[layout-pivot-table]]></category>
            <category><![CDATA[format-pivot-table]]></category>
            <category><![CDATA[pivot-tables]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Wed, 25 Jan 2023 05:22:26 GMT</pubDate>
            <atom:updated>2023-01-25T15:57:12.129Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/220/1*o_jsbcGIzjz3VxMTulqRMg.png" /></figure><h4>Introduce PivotTable, Layout, Format, Collapse, and Expand Field</h4><p>As a data analyst or work that requires a summary of data, a pivot table is needed because it makes it easy to make summary reports. PivotTables are so named because we can easily pivot fields in the table from a row to a column and vice versa to create a different layout</p><p>On this occasion, we will find out about pivot tables. Maybe in the discussion this it will be directly worked based on several questions.</p><h4><strong>Summarize Grocery Sales at Several Grocery Stores</strong></h4><p>The data used is sales data from a store. Each row contains the number of units sold and revenue for a product at a store, as well as the month and year of the sale. The product group (fruit, milk, cereal, or ice cream) is also included.</p><p>Here are the steps:</p><ol><li>Place the cursor anywhere in the data. Then, in the <strong>Tables</strong> group on the <strong>Insert </strong>tab, click the <strong>PivotTable</strong> button. (The Create PivotTable dialog box opens with the Select a Table or Range option button selected by default. Excel guesses at the data range to be included in the PivotTable.)</li><li>Select the <strong>New Worksheet</strong> option button and click <strong>OK</strong>. (Instead of placing the PivotTable in a new worksheet, you could choose to put it in the current one. In that case, select the Existing Worksheet option. Then, in the Location box, enter the cell in the upper-left corner of the range that will contain the PivotTable.)</li><li>The PivotTable Fields pane opens. (If the PivotTable Fields pane is not open, <strong>just right-click any cell in the PivotTable and choose Show Field List.)</strong></li></ol><p>We can use the <strong>checkboxes</strong> at the top of this pane to select which fields the <strong>PivotTable</strong> should include. In addition, you can drag PivotTable <strong>fields, or headings</strong>, from the list at the top of the pane into the boxes, or zones, at the bottom of the pane to specify how the PivotTable will summarize and display our data. The four boxes are as follows:</p><ul><li><strong>Filters:</strong> For fields dragged to this box, <strong>we can easily pick any subset of field values</strong>, so the PivotTable shows calculations based only on that subset.</li><li><strong>Columns:</strong> Fields dragged to this box are <strong>listed across the top row of the PivotTable in the order in which they appear in this box.</strong></li><li><strong>Rows: </strong>Fields dragged to this box are <strong>listed on the left side of the PivotTable in the order in which they appear in this box.</strong></li><li><strong>Values: </strong>Fields dragged to this box are <strong>summarized mathematically in the table.</strong></li></ul><p>4. Drag the <strong>Month field </strong>to the <strong>Filters</strong> <strong>box</strong>. This will let you easily select any subset of months</p><p><strong>Notice:</strong> that the PivotTable updates automatically to reflect this change. This will happen with each change we make.</p><p>5. Drag the <strong>Values field</strong> to the <strong>Columns box</strong></p><p>6. Drag the <strong>Year, Group, Product, and Store fields</strong>, in that order, to the <strong>Rows box</strong>. Excel will summarize data first by year, then for each product group within a given year, then by product within each group, and finally each product by store.</p><p>7. Drag the <strong>Units</strong> <strong>and Revenue fields,</strong> in that order, to the <strong>Values box.</strong></p><p>If we want to change the method of calculation for a data field to an average, a count, or something else, <strong>simply click the data field and choose Value Field Settings.</strong></p><p>The following is the result of summarize grocery sales at several grocery stores:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/324/1*jvcfsp3RVr7PiiiqlBnE3g.png" /></figure><h4>PivotTable Layouts</h4><p>To see the options of <strong>PivotTable Layouts</strong>, place our cursor anywhere in the <strong>PivotTable</strong>. Then, in the <strong>Layout group</strong> on the <strong>Design tab</strong>, click <strong>Report Layout</strong>, and choose one of the following layout options:</p><ul><li><strong>Show in Compact Form:</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/382/1*QWrrFFgrkI_1jIG7gwQQzA.png" /></figure><ul><li><strong>Show in Outline Form:</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/646/1*UrV-e5kT23JFW00jLp3fOg.png" /></figure><ul><li><strong>Show in Tabular Form:</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/646/1*CDAcRalPoFWtNqqarrCE5w.png" /></figure><h4>Change the Format of a Field in a PivotTable</h4><p>For example, to change the format of a column field, follow these steps:</p><ul><li>Right-click the column heading for the column field we want to reformat, and choose <strong>Format Cells</strong>.</li><li>In the <strong>Format Cells dialog box</strong>, choose the format that we want, and then click<strong> OK</strong>.</li></ul><p>We can also change the format of a field from the <strong>PivotTable Field pane.</strong> Here’s how:</p><ul><li>Click the arrow to the right of the field in one of the boxes at the bottom of the <strong>PivotTable Field pane and choose Field Settings.</strong></li><li>Click the <strong>Number Format</strong> button and <strong>click OK</strong>.</li><li>In the <strong>Number Format </strong>dialog box, choose the format that we want, and then click<strong> OK</strong>.</li></ul><h4>Collapse and Expand Fields</h4><p>We can easily <strong>collapse</strong> and <strong>expand</strong> fields in PivotTables for easier viewing. <strong>To collapse a field, simply click the minus (–) sign to the left of the field’s name.</strong> All the listings below that field will collapse into a single row, and <strong>the minus sign will change to a plus (+) sign.</strong></p><p>We can also collapse or expand every listing in an entire field. Here’s how:</p><ul><li>Select any cell containing a member of the field we want to collapse or expand</li><li>In the <strong>Active Field</strong> <strong>group</strong> on the <strong>PivotTable Analyze tab</strong>, click the <strong>Collapse Field</strong> button(It’s the one on the right with a red minus sign as collapse and positive sign as expand).</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/337/1*7KJlKiwGDeTCicARu0QHAw.png" /><figcaption><strong>Active Field Group</strong></figcaption></figure><ul><li>The Groups Collapsed worksheet show the result:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/646/1*CDAcRalPoFWtNqqarrCE5w.png" /><figcaption><strong>Before Collapse</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/645/1*ijxM6F3Z4T5p8DOd3aaGUQ.png" /><figcaption>After Collapse (1)</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/643/1*YUDsRSX3QQvhAspUmEPYUQ.png" /><figcaption>After Collapse (2)</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/649/1*m2G4YzQxdiSJn5oNtSzBuQ.png" /><figcaption>After Collapse (3)</figcaption></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ee62a84a8624" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[SUMIF, AVERAGEIF, SUMIFS, AVERAGEIFS, MAXIFS, and MINIFS Functions]]></title>
            <link>https://medium.com/@afer.sptr/sumif-averageif-sumifs-averageifs-maxifs-and-minifs-functions-1bf98f99af5?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/1bf98f99af5</guid>
            <category><![CDATA[averageifs-function]]></category>
            <category><![CDATA[sumif-function]]></category>
            <category><![CDATA[sumifs-function]]></category>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[averageif-function]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Sat, 21 Jan 2023 14:22:21 GMT</pubDate>
            <atom:updated>2023-01-21T14:22:21.864Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2WLCMqTv01IvgVn8sLjyrA.png" /><figcaption>Source: <a href="https://www.itlektor.eu/excel-funkcie-sumif-averageif-countif">https://www.itlektor.eu/excel-funkcie-sumif-averageif-countif</a></figcaption></figure><p>The SUMIF, AVERAGEIF, SUMIFS, AVERAGEIFS, MAXIFS, and MINIFS formulas are used the same as the COUNTIF and COUNTIFS formulas.</p><h4>SUMIF FUNCTION</h4><p>The <em>SUMIF</em> function to sum values ​​in a range that meet specified criteria.</p><p>Here is the formula from <em>SUMIF</em>:</p><p><strong><em>=SUMIF(range,criterion,[sum_range])</em></strong></p><p>Where:</p><ul><li><strong><em>range</em>:</strong> The range of cells that you want to evaluate with a criterion</li><li><strong><em>criterion</em>:</strong> A number, date, or expression that determines whether a given cell in the <em>sum_range</em> is added</li><li><strong><em>sum_range</em>:</strong> The range of cells that are added. If <em>sum_range</em> is omitted, it is assumed to be the same as <em>range</em>.</li></ul><h4>AVERAGEIF FUNCTION</h4><p>The <em>AVERAGEIF</em> function is used to return the average value (arithmetic mean) of all cells in a range that meet a criterion.</p><p>Here is the formula from <em>AVERAGEIF</em>:</p><p><strong><em>=AVERAGEIF(range,criterion,[average_range])</em></strong></p><h4>SUMIFS FUNCTION</h4><p><em>SUMIFS </em>and <em>AVERAGEIFS</em> are used to add up all of its arguments that meet some criteria.</p><p>Here is the formula from <em>SUMIFS</em>:</p><p><strong><em>=SUMIFS(sum_range,range1,criterion1,range2,criterion2,…,rangeN, criterionN)</em></strong></p><p>Where:</p><ul><li><strong><em>sum_range</em></strong>: Range of cells to sum</li><li><strong><em>range1</em></strong>: The range tested using criterion1</li><li><strong><em>criterion1</em></strong>: Criterion that determines which cells in <em>range1</em> to add</li><li><strong><em>range2,criterion2,….,rangeN,criterionN</em></strong>: Additional ranges and associated criteria. We can insert up to 127 range/criterion pairs.</li></ul><h4>AVERAGEIFS FUNCTION</h4><p><em>AVERAGEIFS</em> function is used to return the average (arithmetic mean) for all cells that meet some criteria.</p><p>Here is the formula from <em>AVERAGEIFS</em>:</p><p><strong><em>=AVERAGEIFS(sum_range,range1,criterion1,range2,criterion2, …,rangeN, criterionN)</em></strong></p><p>The following is an example of using the SUMIF, AVERAGEIF, SUMIFS, and AVERAGEIFS formulas:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VCbDbGx0am8OuNjtcvPObg.png" /></figure><p>The following is an example of using the MAXIFS and MINIFS formulas:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*73WAJKt0MwJEeWDfePSGCw.png" /><figcaption>MAXIFS Function</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1YS9GhYvFf1Pm_XAAB2Kwg.png" /><figcaption>MINIFS Function</figcaption></figure><p>That’s all for our discussion about SUMIF, AVERAGEIF, SUMIFS, AVERAGEIFS, MAXIFS, and MINIFS. I look forward to your suggestions and comments. Thank you 😆 😅</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1bf98f99af5" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[COUNTIF, COUNTIFS, COUNT, COUNTA, and COUNTBLANK Functions]]></title>
            <link>https://medium.com/@afer.sptr/countif-countifs-count-counta-and-countblank-functions-35afc1b912de?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/35afc1b912de</guid>
            <category><![CDATA[countblank]]></category>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[counta]]></category>
            <category><![CDATA[count-functions]]></category>
            <category><![CDATA[countif]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Sat, 21 Jan 2023 05:40:16 GMT</pubDate>
            <atom:updated>2023-01-21T05:40:16.518Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/640/1*Q6ym1-ZjPuCUVK8hRqyeSQ.jpeg" /><figcaption>Source: <a href="https://www.dmiftah.com/2022/03/rumus-count-counta-countif-countifs-microsoft-excel.html">https://www.dmiftah.com/2022/03/rumus-count-counta-countif-countifs-microsoft-excel.html</a></figcaption></figure><p>Sometimes during work, we are asked to count the amount of data specifically, for example, we are asked to count the number of names Jenifer orders with a total of more than 100. Therefore, we need the COUNTIF, COUNTIFS, COUNT, COUNTA, and COUNTBLANK functions to help calculate the amount from a range of data that we need.</p><h4>COUNTIF FUNCTION</h4><p>The<em> COUNTIF</em> function lets us count the number of cells in a range that meet criteria that are defined on the basis of one row or column of the worksheet.</p><p>Here is the formula for COUNTIF:</p><p><strong><em>=COUNTIF(range,criterion)</em></strong></p><p>Where:</p><ul><li><strong><em>range:</em></strong> is the range of cells in which we want to count cells meeting a given criterion</li><li><strong><em>criterion:</em></strong> is a number, date, or expression that determines whether to count a given cell in the range.</li></ul><p><em>COUNTIFS</em> allows the criteria to involve more than one column or multiple conditions in one column.</p><h4>COUNTIFS FUNCTION</h4><p>To facilitate many criterion, we can use the <em>COUNTIFS</em> formula.</p><p>Here is the formula from <em>COUNTIFS:</em></p><p><strong><em>=COUNTIFS(range1,criterion1,range2,criterion2,…,range_n,criterion_n)</em></strong></p><p>Where:</p><ul><li><strong><em>range1</em></strong>: The first range to evaluate the associated criteria</li><li><strong><em>criterion1</em></strong>: A criterion in the form of a number, expression, cell reference, or text that determines which cells to count. For example, criteria can be expressed as 32, “&gt;32”, B4, “apple” or “32”</li><li><strong><em>range_n, criterion_n, … Optional</em></strong>: Additional ranges and associated criteria. Up to 127 range/criteria pairs are allowed.</li></ul><h4>COUNT FUNCTION</h4><p>The <em>COUNT</em> function counts the number of cells that contain numbers, and counts the numbers in the argument list.</p><p>The following is the formula for COUNT:</p><p><strong><em>=COUNT(value1, [value2], …)</em></strong></p><p>Where:</p><ul><li><strong><em>value1</em></strong>: The first item, cell reference, or range for which we want to count numbers</li><li><strong><em>value2, … Optional</em></strong>: Up to 255 additional items, cell references, or ranges for which we want to count numbers.</li></ul><p>with notes:</p><ul><li>Arguments that are numbers, dates, or text representations of numbers (for example, numbers enclosed in quotation marks, such as “1”) are counted</li><li>Logical values ​​and text representations of numbers that we type directly into the argument list are counted</li><li>Arguments that are error values ​​or text that cannot be translated into numbers are not counted</li><li>If the argument is an array or reference, only the numbers in the array or reference are counted. Blank cells, logical values, text, or error values ​​in arrays or references are not counted</li><li>If we want to count logical values, text, or error values, use the <em>COUNTA</em> function</li><li>If we want to count only the numbers that meet certain criteria, use the <em>COUNTIF</em> function or the <em>COUNTIFS</em> function.</li></ul><h4>COUNTA FUNCTION</h4><p>The <em>COUNTA</em> function counts the number of nonblank cells in a range.</p><p>The following is the formula for the COUNTA function:</p><p><strong><em>=COUNTA(value1, [value2], …)</em></strong></p><p>Where:</p><ul><li><strong><em>value1</em></strong>: The first argument represents the value you want to calculate</li><li><strong><em>value2, … Optional</em></strong>: Additional arguments specifying the values ​​you want to calculate, up to a maximum of 255 arguments.</li></ul><p>The <em>COUNTA</em> function counts cells that contain each type of information, including error values ​​and empty text (“ ”). For example, if the range contains a formula that returns the empty string, the <em>COUNTA</em> function calculates that value. <strong>The <em>COUNTA</em> function does not count empty cells</strong>.</p><h4>COUNTBLANK FUNCTION</h4><p>The <em>COUNTBLANK</em> function is used to count the number of blank cells in a range of cells.</p><p>The following is the formula for the <em>COUNTBLANK</em> function:</p><p><strong><em>=COUNTBLANK(range)</em></strong></p><p>Where:</p><ul><li><strong><em>range</em></strong>: The range in which you want to count blank cells.</li></ul><p>Cells with formulas that return “ ” (blank text) are also counted. Cells with a value of zero are not counted.</p><p>The following is an example of the results of using the<em> COUNTIF, COUNTIFS, COUNT, COUNTA,</em> and <em>COUNTBLANK </em>functions:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kJKnrUmuRVGU0qNDgFwJsQ.png" /></figure><p>The ampersand <strong>(&amp;)</strong> symbol to concatenate the reference. If we look together, the characters <strong>&lt;&gt;, &gt;=, &lt;=</strong> use quotation symbols. This is because the character is treated as a text.</p><p>If we want to find a name with n letters, then we can use the wildcard <strong>“?”</strong>. The question mark matches any character.</p><p>That’s all for our discussion about COUNTIF, COUNTIFS, COUNT, COUNTA, and COUNTBLANK functions. I look forward to suggestions and input from you guys. Thank you 😜 😅</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=35afc1b912de" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[IF, IFERROR, IFS, CHOOSE, SWITCH, and the IS functions]]></title>
            <link>https://medium.com/@afer.sptr/if-iferror-ifs-choose-switch-and-the-is-functions-4c0df9fffad1?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/4c0df9fffad1</guid>
            <category><![CDATA[data-manipulation]]></category>
            <category><![CDATA[if-function]]></category>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[switch-function]]></category>
            <category><![CDATA[data-analysis]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Sat, 21 Jan 2023 03:50:19 GMT</pubDate>
            <atom:updated>2023-01-21T03:50:19.670Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pCU8d0od1cDMESB1DrO9Sw.png" /></figure><p>While working with data and analyzing it, we need a function that can return the results that only we want. Therefore, we can use the <em>IF, IFERROR, IFS, SWITCH, CHOOSE,</em> and <em>IS</em> functions.</p><p><strong>IF FUNCTION</strong></p><p>An<em> IF </em>formula begins with a condition such as <strong>A1&gt;10</strong>. If the condition is true, the formula returns the first value listed in the formula. Otherwise, we move on within the formula and repeat the process.</p><p>The following is an example of using a simple IF formula in hedging calculations:</p><pre>=IF(A9&lt;exprice;exprice-A9;0)*Nputs</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/610/1*yepdy_bR1EGTCBG1A7WiZw.png" /></figure><p>If we look at the above code together, to calculate the final put value, then we can calculate it under the condition that the f<strong>inal stock price is less than the exprice,</strong> then the calculation of the final put value can be done using <strong>the exprice formula — final stock price multiplied by the value of put or Nputs.</strong></p><p><strong>Where, if the final stock price is greater than the exprice value, then the value to be entered in the final put value column is zero (0).</strong></p><p><strong>Nested IF Function</strong></p><p>To add multiple conditions to an <em>IF </em>formula, we only need to add comma-separated <em>IF</em> statements inside the<em> IF </em>formula.</p><p>Here is an example of a <em>nested IF</em> function to calculate the quantity discount cost for an order:</p><pre>=IF(A9&lt;=_cut1;price1*A9;IF(A9&lt;=_cut2;price2*A9;IF(A9&lt;=_cut3;price3*A9;price4*A9)))</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/510/1*gAswrdZz6iIdi9E7J8b13w.png" /></figure><p>To understand a <em>nested IF </em>formula, we have to read it slowly from left to right, as an example is the code above. Recall that<em> IF</em> statements are evaluated from left to right. If the order quantity is less than or equal to 500 (cut1), the cost is given by <strong>price1*A9</strong>. If the order quantity is not less than or equal to 500, the formula checks to see whether the order quantity is less than or equal to 1,200. If this is the case, the order quantity is between 501 and 1,200, and the formula computes a cost of <strong>price2*A9</strong>. Next, the formula checks whether the order quantity is less than or equal to 2,000. If this is true, the order quantity is between 1,201 and 2,000, and the formula computes a cost of <strong>price3*A9</strong>. Finally, if the order cost has not yet been computed, the formula defaults to the value <strong>price4*A9</strong>. In each case, the <em>IF</em> formula returns the correct order cost.</p><h4>IF with AND and OR</h4><p><strong>IF with AND</strong></p><p>To understand the use of AND, here is an example for calculating moving average trading to a buy-and-hold strategy:</p><pre>=IF(AND(C24=&quot;No&quot;;B24&gt;D24);&quot;Yes&quot;;&quot;No&quot;)</pre><p>Here is the result of IF with AND:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Zx66PAnpTXn0TK9bTj3aCg.png" /></figure><p>If we look at the code above, the <em>IF </em>formula contains an <em>AND</em> statement. The statement that is in the <em>AND</em> contains two conditions that will be used to determine whether a purchase will be made under these conditions or not. In other words, the <em>AND</em> statement is used to state that there are two conditional requirements in a “Yes” or “No” decision. Where <strong>if in cell C24 there is no purchase or “No” and the price value (P) is greater than the MA value, it will produce the condition for the sentence “Yes” in cell E24, conversely, if these two conditions are not met then it will produce a condition with the sentence “No” as a sign not to be purchased.</strong></p><p><strong>IF with OR</strong></p><p>To understand the use of <em>OR in IF</em>, we will take an example of data from a craps game. Where if the values ​​that come out are 2, 3, and 12 we will lose, whereas if the values ​​that come out are 7 and 11 we will win, meanwhile other than the values ​​of these two conditions the player will keep going to play:</p><pre>=IF(OR(A5=2;A5=3;A5=12);&quot;Lose&quot;;IF(OR(A5=7;A5=11);&quot;Win&quot;;&quot;Keep Going&quot;))</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/298/1*EZeJUp6NtuO7ITjcxbRHqA.png" /></figure><p>If we look at it together, the <em>OR</em> statement requires <em>n</em> as many <em>OR</em> statements depending on the conditions we are going to make. As for <em>AND</em>, what determines how much or not is the condition in the <em>AND</em> statement. So, in simple terms, the <em>AND</em> statement is used to provide many conditions where these conditions are related to each other,<strong> if the first condition is not met, it will produce FALSE.</strong> As for the <em>OR</em> statement, it is used to write many conditions but is divided into several conditions, <strong>where each of the existing conditions is used as an option</strong>.</p><h4>IFERROR</h4><p>Sometimes, we will produce an error value from our calculation results, whether it is a formula error or the data we insert is not in the cell we want. For that, we need a function that can ignore the error value and change it to text or something else. We can use <em>IFERROR</em> to deal with error values ​​that might be generated from the formulas we use.</p><p>Here are some examples of errors that might appear:</p><ul><li><strong>#DIV/0!</strong>: There is a value divided by the number 0</li><li><strong>#VALUE!</strong>: The data type entered is incorrect or inappropriate</li><li><strong>#NAME?</strong>: Range name, table name or function name is not recognized</li><li><strong>#NUM!</strong>: The formula returns an invalid numeric value</li><li><strong>#REF!</strong>: There is an invalid reference</li><li><strong>#N/A</strong>: The value is not found</li><li><strong>#####</strong>: Cells or columns are not wide enough</li><li><strong>#GETTING_DATA</strong>: Excel is still in the process of calculating data.</li></ul><p>Here is an example of the types of error:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/699/1*l_3C4RUTVMDUO-2ufpwkzQ.png" /></figure><p>The following is an example of using <em>IFERROR</em> in calculating the average employee:</p><pre>=IFERROR(VLOOKUP(D11;TARGET;2;FALSE);&quot;&quot;)</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/742/1*3tQGUnyhOyClVlKTEg3ySA.png" /></figure><p>We can see in the code above and the result, where if the <em>VLOOKUP</em> formula returns an error, it will be written as a space. This can be seen in cells F13 and F14, where these cells will produce errors but <strong>have been replaced with spaces.</strong></p><p>Another way to be able to perform calculations even though there are error results from the column that we will use is by using the <em>AGGREGATE</em> formula which is written as follows:</p><pre>=AGGREGATE(1;6;E11:E15)</pre><p>The syntax of the AGGREGATE function is:</p><p><strong><em>AGGREGATE(function_number,option,array)</em></strong></p><p>The arguments are defined as follows:</p><ul><li><strong><em>function_number:</em></strong> A code between 1 and 19 that gives the function involved in your calculations. For example, <strong>1</strong> equals <strong>AVERAGE</strong> and 9 equals <strong>SUM</strong></li><li><strong>option: </strong>A code that gives the type of cells that should be ignored in your calculations (see the following table). We used <strong>6</strong> so that error values are ignored.</li><li><strong><em>array:</em></strong> The range of cells used in your calculations. As shown in <strong>cell E18</strong>, the formula <strong>AGGREGATE(1,6,E11:E15)</strong> correctly computes the average of the listed salaries <strong>(74.6667)</strong>.</li></ul><p>The following is a list of <strong>options</strong>:</p><ul><li><strong>0:</strong> or omitted Ignore nested <em>SUBTOTAL</em> and <em>AGGREGATE </em>functions</li><li><strong>1: </strong>Ignore hidden rows and nested <em>SUBTOTAL</em> and <em>AGGREGATE</em> functions</li><li><strong>2:</strong> Ignore error values and nested <em>SUBTOTAL</em> and <em>AGGREGATE</em> functions</li><li><strong>3; </strong>Ignore hidden rows, error values, and nested <em>SUBTOTAL</em> and <em>AGGREGATE</em> functions</li><li><strong>4:</strong> Ignore nothing</li><li><strong>5:</strong> Ignore hidden rows</li><li><strong>6</strong>:<strong> </strong>Ignore error values</li><li><strong>7:</strong> Ignore hidden rows and error values.</li></ul><h4>IFS FUNCTION</h4><p>The <em>IFS</em> function works like the <em>IF</em> function in general, but this <em>IFS</em> is used to replace the nested <em>IF</em> function to make it easier to read and not confused by adding parentheses. The <em>IFS</em> function only requires one parenthesis, and if there are additional conditions, before writing these additional conditions, we must write a <em>TRUE</em> statement as a sign that apart from these conditions, there are other conditions that can be used as options.</p><p>The following is an example of using <em>IFS</em> in a craps game:</p><pre>=IFS(OR(A5=2;A5=3;A5=12);&quot;LOSE&quot;;OR(A5=7;A5=11);&quot;WIN&quot;;TRUE;&quot;KEEP GOING&quot;)</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*bH-keAi2l6SSFlasIpk5QA.png" /></figure><p>The following is an example of using <em>IFS</em> in calculating quality discount costs:</p><pre>=IFS(A9&lt;=_cut1;price1;A9&lt;=_cut2;price2;A9&lt;=_cut3;price3;TRUE;price4)</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HBBtVDH6nrD_1uVSfWdPNw.png" /></figure><p>If the order quantity is less than or equal to 500, a unit price of $3 is returned; if the order quantity is between 501 and 1200, a unit price of $2.70 is returned, if the order quantity is between 1201 and 2000, a unit price of $2.30 is returned. Otherwise (because of the word <strong>TRUE</strong>), a unit price of $2 is returned. Again, note that we type the word <em>IFS</em> only once and need only one ending parenthesis. Also note that the old <em>IF</em> formula defaults to the last result if none of the given conditions are <strong>TRUE, </strong>with the <em>IFS</em> formula, <strong>we need to type TRUE to make the <em>IFS</em> statement return the last listed result.</strong></p><h4>CHOOSE FUNCTION</h4><p>The CHOOSE function returns a value from a list of values based on a given position. The syntax of the CHOOSE function is:</p><p><strong><em>CHOOSE(index_num,value1,[value2],…).</em></strong></p><p>Here, the values can be ranges. If the index equals <em>n</em>, then the <strong>index_num</strong> value is<em> n</em>.</p><p>The following is an example of using <em>CHOOSE</em> for a blackjack card game:</p><pre>=CHOOSE(G3;-1;1;1;1;1;1;1;0;-1;-1)</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xAYQX3Rs3HYZOj8H66N41Q.png" /></figure><p>Basically, when cards 2 through 7 are dealt from the deck, this is good for the player, so the player counts those cards as a +1. When a 9, a 10, or an ace (listed as 1) is dealt from the deck, this is bad for the player, and the card is counted as a –1. Finally, an 8 is neutral and is counted as a 0.</p><p><strong>Column I</strong> tracks the cumulative point total. For example, after seven cards have been drawn, the total is +3, which is relatively favorable to the player.</p><p>The following is an example of using <em>CHOOSE </em>to calculate quarters in a year:</p><pre>=CHOOSE(H5;2;2;2;3;3;3;4;4;4;1;1;1)</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Noa36Pv6Xlf3bpgY2KHHNQ.png" /></figure><p>Suppose that months 1 through 3 of the year are quarter 2, months 4 through 6 are quarter 3, months 7 through 9 are quarter 4, and months 10 through 12 are quarter 1. So, because the month we want to know is the 7th month, then if we use the <em>CHOOSE</em> formula it will result in the 7th month being in the 4th Quarter of a year.</p><h4>SWITCH FUNCTION</h4><p>This function evaluates one value (called the expression) against a list of values and returns the result corresponding to the first matching value. If there is no match, an optional default value may be returned. The <em>SWITCH</em> function can evaluate as many as 126 matching values and results.</p><p>Here is the <em>SWITCH</em> formula:</p><p><strong><em>=SWITCH(Value to switch, Value to return1…[2–126], Value to return if result1…[2–126], Value to return if no match)</em></strong></p><p>The following is an example of using the <em>SWITCH </em>formula for grouping clothing size categories:</p><pre>=SWITCH(G4;&quot;XXL&quot;;&quot;REALLY BIG&quot;;&quot;XL&quot;;&quot;EXTRA LARGE&quot;;&quot;L&quot;;&quot;LARGE&quot;;&quot;M&quot;;&quot;MEDIUM&quot;;&quot;S&quot;;&quot;SMALL&quot;;&quot;XS&quot;;&quot;EXTRA SMALL&quot;;&quot;XXS&quot;;&quot;REALLY SMALL&quot;;&quot;CODE IS WRONG&quot;)</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DFBL218oBxJf6bfXVL8taw.png" /></figure><p>Where the <em>SWITCH</em> formula is useful for matching values ​​in<strong> column G </strong>with values ​​in <strong>column B</strong> or at predetermined values.</p><h4>IS FUNCTION</h4><p>The <em>IS </em>function is used to check for a specific value and returns <strong>TRUE</strong> or <strong>FALSE</strong> depending on the result. For example, the <strong>ISBLANK</strong> function returns the logical value <strong>TRUE</strong> if its value argument is a reference to an empty cell. Otherwise, this function returns <strong>FALSE</strong>.</p><p>The following are various of <em>IS</em> functions:</p><ul><li><strong>ISBLANK<em>(value)</em>:</strong> Returns <strong>TRUE</strong> if the value is a blank cell and <strong>FALSE</strong> otherwise.</li><li><strong>ISERR<em>(cell)</em>:</strong> Returns <strong>TRUE</strong> if the cell’s formula returns an error that is not an <strong>#N/A </strong>error and <strong>FALSE</strong> otherwise</li><li><strong>ISERROR<em>(cell)</em>:</strong> Returns <strong>TRUE</strong> if the cell’s formula returns any error and <strong>FALSE </strong>otherwise (#N/A, #VALUE!, #REF!, #DIV/0!, #NUM!, #NAME?, or #NULL!)</li><li><strong>ISLOGICAL<em>(cell)</em></strong>: Value refers to a logical value</li><li><strong>ISNA<em>(cell)</em>:</strong> Returns <strong>TRUE</strong> if a cell’s formula returns an <strong>#N/A</strong> error and <strong>FALSE</strong> otherwise</li><li><strong>ISNONTEXT<em>(value)</em></strong>: Values ​​that refer to non-text items. (Note that this function returns <strong>TRUE</strong> if the value refers to an empty cell.)</li><li><strong>ISNUMBER<em>(value)</em>:</strong> Returns <strong>TRUE</strong> if the value is a number and <strong>FALSE</strong> otherwise.</li><li><strong>ISREF<em>(cell)</em></strong>: A value that refers to a reference</li><li><strong>ISTEXT<em>(value)</em></strong>: Returns <strong>TRUE</strong> if the value is text and <strong>FALSE</strong> otherwise</li><li><strong>ISFORMULA<em>(cell)</em></strong>: Returns <strong>TRUE</strong> if the cell contains a formula and <strong>FALSE </strong>otherwise.</li></ul><p>Here is an example of the result from <em>IS</em> function:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zqwXYiXsrdx7TTpDPPQPfw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Ev7h4ytNxoZNhEt3FKlGNg.png" /></figure><p>That’s all for our discussion about <em>IF, IFERROR, IFS, CHOOSE, SWITCH</em>, and <em>IS</em> functions on Excel. I look forward to your suggestions and comments. Thank you 😉 😆 😜.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4c0df9fffad1" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Lookup Functions]]></title>
            <link>https://medium.com/@afer.sptr/lookup-functions-728fc100c067?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/728fc100c067</guid>
            <category><![CDATA[hlookup]]></category>
            <category><![CDATA[vlookup]]></category>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[lookup-function]]></category>
            <category><![CDATA[data-analysis]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Wed, 18 Jan 2023 16:40:57 GMT</pubDate>
            <atom:updated>2023-01-18T16:40:57.175Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/240/1*2hlYk0e_c6E22Qg9DeH6Pw.png" /></figure><p>While working as a data analysts, we are sometimes required to find out the specifics of a product, whether it is the price of the product, the number of products, or something else. If we search one by one, it will make it difficult for us and the level of accuracy in finding data is also not quite right, because the data we will work with will have many rows. Therefore, we need the help of a function that makes it easier for us to search for something in large data, so that errors can be minimized.</p><p>The LOOKUP function in Excel performs a search for matches, estimates in a range of one column or one row. As well as returning the corresponding value from a range in one row or one other column.</p><p>In a vertical lookup, the data to be searched is based on the first column in a worksheet range. Whereas in horizontal lookup, the data to be searched is based on the first row in a worksheet range.</p><p>If you are using Microsoft 365, use XLOOKUP, not only is it faster, it lets you search in any direction (up, down, left, right).</p><h4>VLOOKUP FUNCTION</h4><p>The syntax of the <em>VLOOKUP</em> function is as follows. The brackets ([ ]) indicate optional arguments.</p><p><strong><em>VLOOKUP(lookup_value,table_range,column_index,[range_lookup])</em></strong></p><p>The following is the description:</p><ul><li><strong><em>lookup_value: </em></strong>The value that wewant to look up in the first column of the table range</li><li><strong><em>table_range: </em></strong>The range that contains the entire lookup table. The table range includes the first column (in which you try to match the lookup value) and any other columns in which we want to look up formula results</li><li><strong><em>column_index: </em></strong>The column number in the table range from which the value of the lookup function is obtained</li><li><strong><em>range_lookup: </em></strong>An optional argument. The point of <em>range_lookup</em> is to allow us to specify an exact or approximate match. If <em>range_lookup</em> is <strong>True</strong> or <strong>omitted</strong>, the first column of the table range must be in ascending numerical order</li><li>If <em>range_lookup</em> is True or omitted and an exact match for the lookup value is found in the first column of the table range, Excel bases the lookup on the row of the table in which the exact match is found.</li><li>If <em>range_lookup</em> is True or omitted and an exact match does not exist, Excel bases the lookup on the largest value in the first column that is less than the lookup value</li><li>If<em> range_lookup</em> is False and an exact match for the lookup value is found in the first column of the table range, Excel bases the lookup on the row of the table in which the exact match is found.</li></ul><p>A <em>range_lookup</em> argument of <strong>1</strong> is equivalent to <strong>True</strong>, whereas a <em>range_lookup</em> argument of <strong>0</strong> is equivalent to <strong>False</strong>.</p><p>For example, If we want to find the annual loan rate of a company. Then we can use <em>VLOOKUP</em> to find the value range of the annual loan rate that has been determined by its composition.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/654/1*n_Be460aEPUm2YkQK1yUwQ.png" /><figcaption><strong>Annual Loan Rate Table</strong></figcaption></figure><p>Here is an example of using the <em>VLOOKUP</em> function:</p><pre>=VLOOKUP(F4;FOCUS;2)+G4*H4</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/817/1*bwB_iWhbY60mQFiffVMagw.png" /><figcaption><strong>Calculation Table of Annual Loan Rate</strong></figcaption></figure><p>If we look at the code above, the cell that will be our calculation is cell F4, and <strong>the name FOCUS is the name of the cell range from A4 to D7 as the table we want to find the value that corresponds to the annual loan.</strong></p><p>And for the index column, <strong>we use number 2, this shows that column 2 in the FOCUS column (cells B4:B7) is the column that will be used as a search for the appropriate result of the calculation.</strong></p><p>Meanwhile, we do not use <em>range_lookup</em> because <strong>column B is already sorted.</strong></p><h4>HLOOKUP FUNCTION</h4><p>In an <em>HLOOKUP</em> function, Excel tries to locate the lookup value in the first row (not the first column) of the table range. For an <em>HLOOKUP</em> function, use the <em>VLOOKUP </em>syntax but change column to row.</p><p>Here is an example of using the <em>HLOOKUP</em> function:</p><pre>=HLOOKUP(C6;TARGET;D6+1)</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/973/1*kVBvZZf4sSd6GEhRBW-UMw.png" /><figcaption><strong>Calculation Rank of Employees</strong></figcaption></figure><p>Let’s take a look at the code above, where cell C6 is the value that we want to find, while the <strong>TARGET</strong> column is a collection of rows from <strong>E5 to G40</strong> as table_range, and <strong>cell D6 as row_index</strong> which will serve as a reference for searching for the appropriate value from <strong>cell C6</strong>.</p><p>Here in cell D6 there is a “+” sign, where this is done to inform the system that the row in the <strong>TARGET</strong> column must be added or added one row from the initial row in the <strong>TARGET</strong> column, because the first row is a description row of the assignment number not as the rank value of each worker.</p><p>If we do not add <strong>1</strong> to cell D6, then it will produce a rank value of 2 for worker 1, <strong>this is not true </strong>because <strong>worker 1 will get rank 5 as having completed task number 2.</strong></p><h4><strong>XLOOKUP FUNCTION</strong></h4><p>Office 365 gives we access to the powerful <em>XLOOKUP</em> function. The syntax of the <em>XLOOKUP </em>function is as follows:</p><p><strong><em>XLOOKUP(lookup_value,lookup_array,return_array,[if_not_found],[match_mode], [search_mode])</em></strong></p><p>The following is the description:</p><ul><li><strong><em>lookup_value: </em></strong>The value that we want to look up</li><li><strong><em>lookup_array: </em></strong>The array where we search for the first match to the lookup value</li><li><strong><em>return_array:</em></strong> The array from which values are returned</li><li><strong><em>if_not_found:</em></strong> An optional argument. If it is omitted and Excel finds no valid match, then an <strong><em>#N/A </em></strong>error is returned</li><li><strong><em>match_mode:</em></strong> An optional argument. <strong>A value of 0 is the default</strong>. This causes Excel to <strong>search for an exact match</strong>. If none is found, Excel defaults to the option you have selected with the <em>if_not_found</em> argument. <strong>A value of –1</strong> results in Excel looking for an exact match<strong>. If none is found, Excel returns the next smaller item.</strong> <strong>A value of 1 </strong>seeks an exact match. <strong>If none is found, Excel returns the next larger item</strong>. <strong>A value of 2</strong> seeks a <strong>wildcard match</strong>, <strong>where *, ?, and ~ have a special meaning.</strong></li><li>Excel interprets wildcard characters as follows: <strong>An *</strong> can represent any number of characters. For example, Jon* could match Jones or Jonas in a lookup formula, while *Jon* could match Ajona, Jona, or Ajon.<strong> A ?</strong> represents a single character. For example, T?a would match Tea or Tia. <strong>A ~</strong> (rarely used) is used to identify a wildcard character. For example, Wayne~* could be used to match Wayne* in a lookup formula.</li><li><strong><em>search_mode:</em></strong> An optional argument. <strong>A value of 1 (the default)</strong> begins the <strong>search with the first item</strong>. <strong>A value of –1 </strong>performs a reverse<strong> search starting at the last item.</strong> <strong>A value of 2</strong> requires <strong>the array be sorted in ascending order.</strong> Then a binary search is performed. <strong>A value of –2</strong> requires <strong>the array be sorted in descending order.</strong> Then a binary search is performed.</li></ul><p>The <em>XLOOKUP</em> function may not be available in excel 2016 and 2019. However, we can add the<em> XLOOKUP</em> function to the Excel adds-in on the adds-in ribbon on the Developer menu. Then we add the files that have been downloaded at the following link: <a href="https://github.com/Excel-DNA/XFunctions/releases">Click here</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/669/1*tJrs6YmL2lGMNkc3UhjoFQ.png" /><figcaption><strong>Baseball Players Table</strong></figcaption></figure><p>Here is an example of using the <em>XLOOKUP</em> function:</p><pre>-- To search for specific player names<br>=XLOOKUP(&quot;Mike Trout&quot;;C4:C880;C4:F880;&quot;no answer&quot;;0)<br><br>-- To lookup Mike Trout as Wildcard<br>=XLOOKUP(&quot;*Trout&quot;;C4:C880;D4:F880;&quot;no answer&quot;;2)<br><br>-- To find the salary value with the first one value &gt;=$25.1 million<br>=XLOOKUP(25100000;F4:F880;C4:E880;&quot;no answer&quot;;-1)<br><br>-- To find the salary value with the last one value &gt;=$29.5 million<br>=XLOOKUP(29500000;F4:F880;C4:C880;&quot;no answer&quot;;1)<br><br>-- To find the value from the first to the last (+!)<br>=XLOOKUP(&quot;*Smith&quot;;C4:C880;C4:F880;&quot;no answer&quot;;2;1)<br><br>-- To find the value from last to the first (-1)<br>=XLOOKUP(&quot;*Smith&quot;;C4:C880;C4:F880;&quot;no answer&quot;;2;-1)<br><br>-- To search for a player&#39;s name but not finding it will result in a No Match because the XLOOKUP formula gives the information &quot;No Match&quot; if it is not found<br>=XLOOKUP(&quot;WAYNE WINSTON&quot;;C4:C880;F4:F880;&quot;No Match&quot;;0;1)<br><br>-- To search for a player&#39;s name but not finding it will result in an error #N/A because the player&#39;s name was not found and no information was given if it was not found<br>=XLOOKUP(&quot;WAYNE WINSTON&quot;;C4:C880;F4:F880;;0;1)</pre><p>Here is the full of result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*g0g9Kyn1aC_0Sotnh64CEw.png" /></figure><p>That’s all for our discussion about <strong>LOOKUP FUNCTIONS</strong> in Excel. I look forward to your suggestions and comments. Thank you 😜</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=728fc100c067" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Get to Know About SQL Pt.11]]></title>
            <link>https://medium.com/@afer.sptr/get-to-know-about-sql-pt-11-7a04d741a965?source=rss-1613b3c71e1e------2</link>
            <guid isPermaLink="false">https://medium.com/p/7a04d741a965</guid>
            <category><![CDATA[data-processing]]></category>
            <category><![CDATA[cursor-sql]]></category>
            <category><![CDATA[sql-view]]></category>
            <category><![CDATA[data-analysis]]></category>
            <category><![CDATA[sql]]></category>
            <dc:creator><![CDATA[Anggi Firdian Saputra]]></dc:creator>
            <pubDate>Fri, 13 Jan 2023 15:41:13 GMT</pubDate>
            <atom:updated>2023-01-13T15:43:43.433Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/262/1*lOzdOdWP0HGuJEeSnDt_Tw.jpeg" /><figcaption>Source: <a href="https://www.edureka.co/blog/sql_view/">https://www.edureka.co/blog/sql_view/</a></figcaption></figure><h4>Using View and Cursor</h4><h4>Using Views</h4><p>Views are virtual tables that provide a logical view of data from a base table. Unlike tables that contain data, views simply contain queries that dynamically retrieve data when used.</p><p>SQLite supports only read-only views, so views may be created and read, but their contents cannot be updated.</p><p>We will be relieved to know that view creation syntax is supported pretty consistently by all the major DBMSs.</p><p>Here are some other common uses:</p><ul><li>To reuse SQL statements</li><li>To simplify complex SQL operations</li><li>After the query is written, it can be reused easily, without having to know the details of the underlying query itself</li><li>To expose parts of a table instead of complete tables</li><li>To secure data. Users can be given access to specific subsets of tables instead of to entire tables</li><li>To change data formatting and representation. Views can return data formatted and presented differently from their underlying tables.</li></ul><p>We can perform <em>SELECT</em> operations, filter and sort data, join views to other views or tables, and possibly even add and update data. (There are some restrictions on this last item. More on that in a moment.)</p><p>Views contain no data themselves, so the data they return is retrieved from other tables. When data is added or changed in those tables, the views will return that changed data.</p><p>Because views contain no data, any retrieval needed to execute a query must be processed every time the view is used. If we create complex views with multiple joins and filters, or if we nest views, we may find that performance is dramatically degraded. Be sure we test execution before deploying applications that use views extensively.</p><p>Here are some of the most common rules and restrictions governing view creation and usage:</p><ul><li>Like tables, views must be uniquely named. (They cannot be named with the name of any other table or view.)</li><li>There is no limit to the number of views that can be created</li><li>To create views, you must have security access. This level of access is usually granted by the database administrator</li><li>Views can be nested. That is, a view may be built using a query that retrieves data from another view. The exact number of nested levels allowed varies from DBMS to DBMS. (Nesting views may seriously degrade query performance, so test this thoroughly before using it in production environments.)</li><li>Many DBMSs prohibit the use of the <em>ORDER BY </em>clause in view queries.</li><li>Some DBMSs require that every column returned to be named; this will require the use of aliases if columns are calculated fields</li><li>Views cannot be indexed, nor can they have triggers or default values associated with them</li><li>Some DBMSs, like SQLite, treat views as read-only queries, meaning you can retrieve data from views but not write data back to the underlying tables. Refer to DBMS documentation for details</li><li>Some DBMSs allow you to create views that do not allow rows to be inserted or updated if that insertion or update will cause that row to no longer be part of the view. For example, if you have a view that retrieves only customers with email addresses, updating a customer to remove his email address would make that customer fall out of the view. This is the default behavior and is allowed, but depending on DBMS, might be able to prevent this from occurring.</li></ul><h4>Creating Views</h4><p>Views are created using the <em>CREATE VIEW</em> statement. Like <em>CREATE TABLE</em>, <em>CREATE VIEW</em> can only be used to create a view that does not exist.</p><p>To remove a view, you use the <em>DROP</em> statement. The syntax is simply <em>DROP VIEW viewname</em>. To overwrite (or update) a view, you must first <em>DROP</em> it and then re-create it.</p><p>Here is an example of using view:</p><pre>-- First, Create View called ProductCustomers<br>CREATE VIEW ProductCustomers AS<br>SELECT cust_name, cust_contact, prod_id<br>FROM Customers, Orders, OrderItems<br>WHERE Customers.cust_id = Orders.cust_id<br>  AND OrderItems.order_num = Orders.order_num;<br><br>-- Call the View ProductCustomers<br>SELECT cust_name, cust_contact<br>FROM ProductCustomers<br>WHERE prod_id = &#39;RGAN01&#39;;</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/339/1*HupLilKx1CHjs2LOuIv8dw.png" /></figure><p>If we see, in the first code, there is code that join the Customers, Orders, and Orderitems tables. Where the code is quite complex if we see. However, we will simplify the code by creating a new table name in the <em>VIEW </em>clause. If we see, the <em>VIEW</em> clause shortens complex code to be simple. We can use <em>VIEW</em> to read and retrieve data according to what we need, for example in the second code above.</p><h4><strong>Using Views to Reformat Retrieved Data</strong></h4><p>Here is an example of formatting data to combine data from multiple columns into one column:</p><pre>CREATE VIEW VendorsLocation AS<br>SELECT concat(RTRIM(vend_name), &#39;  (&#39;, RTRIM(vend_city), &#39;)&#39;) AS vend_location<br>FROM vendors<br>ORDER BY vend_name;</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/262/1*-B3iyE1f4aZUX6xTbuKh6A.png" /></figure><h4>Using Views to Filter Unwanted Data</h4><p>For example, we only want data on customers who have email. So we can code it as follows:</p><pre>CREATE VIEW CustomerEMailList AS<br>SELECT cust_id, cust_name, cust_email<br>FROM Customers<br>WHERE cust_email IS NOT NULL<br>ORDER BY cust_name;</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/528/1*4mcQelFCCcVEPGu2eam9Cg.png" /></figure><p>If a <em>WHERE</em> clause is used when retrieving data from the view, the two sets of clauses (the one in the view and the one passed to it) will be combined automatically.</p><h4>Using Views with Calculated Fields</h4><p>As an example of using the <em>VIEW</em> clause for calculated fields and <em>JOIN</em> clauses as follows:</p><pre>CREATE VIEW OrderTotalItems AS<br>SELECT cust_name,<br>       Orders.order_num,<br>       (SELECT SUM(quantity * item_price)<br>        FROM Orderitems<br>        WHERE Orderitems.order_num = Orders.order_num) AS OrderTotal<br>FROM Customers, Orders, Orderitems<br>WHERE Customers.cust_id = Orders.cust_id<br>  AND Orders.order_num = Orderitems.order_num<br>GROUP BY cust_name, Orders.order_num<br>ORDER BY OrderTotal;<br><br>SELECT * FROM OrderTotalItems;</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/384/1*xv_nYXyiPe_JGlOIJzJ2NA.png" /></figure><h4>Using Cursors</h4><p>A CURSOR (CURrent Set of Records) is a temporary workstation created in the database server when the SQL statement is executed.</p><p>Different DBMSs support different cursor options and features. Some of the more common ones are:</p><ul><li>The capability to flag a cursor as read-only so that data can be read but not updated or deleted</li><li>The capability to control the directional operations that can be performed (forward, backward, first, last, absolute position, relative position, and so on)</li><li>The capability to flag some columns as editable and others as not editable</li><li>Scope specification so as to be able to make the cursor accessible to the specific request that created it (a stored procedure, for example) or to all requests</li><li>Instructing the DBMS to make a copy of the retrieved data (as opposed to pointing to the live data in the table) so that data does not change between the time the cursor is opened and the time it is accessed.</li></ul><p>Cursors are used primarily by interactive applications in which users need to scroll up and down through screens of data, browsing or making changes.</p><p>Using cursors involves several distinct steps:</p><ul><li>Before a cursor can be used, it must be declared (defined)</li><li>This process does not actually retrieve any data, it merely defines the <em>SELECT </em>statement to be used and any cursor options</li><li>Once it is declared, the cursor must be opened for use</li><li>This process actually retrieves the data using the previously defined <em>SELECT</em> statement</li><li>With the cursor populated with data, individual rows can be fetched (retrieved) as needed</li><li>When it is done, the cursor must be closed and possibly deallocated (depending on the DBMS).</li></ul><p>Once a cursor is declared, it may be opened and closed as often as needed. Once it is open, fetch operations can be performed as often as needed.</p><h4>Creating Cursors</h4><p>Cursors are created using the DECLARE statement, which differs from one DBMS to the next. DECLARE names the cursor and takes a SELECT statement, complete with WHERE and other clauses if needed.</p><p>Here is an example of using the CURSOR clause on DB2, MariaDB, MySQL, and SQL Server:</p><pre>DECLARE CustCursor CURSOR <br>FOR <br>SELECT * FROM Customers <br>WHERE cust_email IS NULL;</pre><p>Here is an example of using the CURSOR clause on Oracle and PostgreSQL:</p><pre>DECLARE CURSOR CustCursor<br>IS<br>SELECT * FROM Customers<br>WHERE cust_email IS NULL;</pre><p>To open the cursor can be as follows:</p><pre>OPEN CURSOR CustCursor</pre><p>When the <em>OPEN CURSOR</em> statement is processed, the query is executed, and the retrieved data is stored for subsequent browsing and scrolling.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XSwP5bQj-V57QOjFeb6zrw.png" /><figcaption>Customers Table</figcaption></figure><p>Here is an example of using the <em>CURSOR</em> clause without using the <em>LOOP</em> clause on MySQL:</p><pre>DELIMITER $$<br>CREATE PROCEDURE cur3()<br>BEGIN<br> DECLARE finished INT DEFAULT 0;<br>    DECLARE name_list CHAR(200) DEFAULT &quot;&quot;;<br>    DECLARE email_list CHAR(200) DEFAULT &quot;&quot;;<br>    DECLARE custcur3 CURSOR FOR SELECT cust_name, cust_email FROM Customers<br>    WHERE cust_email IS NOT NULL;<br>    DECLARE CONTINUE HANDLER FOR NOT FOUND SET finished = 1;<br>    OPEN custcur3;<br>    FETCH custcur3 INTO name_list, email_list;<br>    SELECT name_list, email_list;<br>    CLOSE custcur3;<br>END$$<br>DELIMITER ;<br><br>-- Call cur3 to show the result<br>CALL cur3();</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/343/1*6pP3K_VZAPqaL72uHDi6oA.png" /></figure><p>Here is an example of using the <em>CURSOR</em> clause using the <em>LOOP</em> clause on MySQL:</p><pre>DELIMITER $$<br>CREATE PROCEDURE cur2(INOUT cust2 CHAR(200))<br>BEGIN<br>    DECLARE finished INT DEFAULT 0; - Defines a variable to store the state of the cursor<br>    DECLARE name_list CHAR(200) DEFAULT &quot;&quot;;<br>    DECLARE email_list CHAR(200) DEFAULT &quot;&quot;; - create variable for list of the name customer and list of the email customer from Customers table<br>    DECLARE custcur2 CURSOR FOR SELECT cust_name, cust_email FROM Customers<br>    WHERE cust_email IS NOT NULL; - create a CURSOR with the name cur2 to store the query results<br>    DECLARE CONTINUE HANDLER FOR NOT FOUND SET finished = 1; - to handle when the results of the cur2 loop run out, the finished variable is set to 1<br>    OPEN custcur2; - Open CURSOR cur2<br>    <br>    get_cust2: LOOP<br>        FETCH custcur2 INTO name_list, email_list; - inserts the result of the first field (cust_name) and the second field (cust_email) from the cursor into the name_list and email_list variable<br>        IF finished = 1 THEN<br>                LEAVE get_cust2; - if the variable done still has a value of 0 then execute the query below<br>        END IF; <br>            SET cust2 = CONCAT(name_list,&quot;, &quot;, email_list);<br>        END LOOP get_cust2; - loop ends when done equals 1<br>    CLOSE custcur2; - Close CURSOR cur2<br>END$$<br>DELIMITER ;<br><br>-- Call cur2 to show the result<br>SET @cust2 = &quot;&quot;;<br>CALL cur2(@cust2);<br>SELECT @cust2;</pre><p>Here is the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/358/1*q5OokEUBleRILChzCgxpew.png" /></figure><p>If we see, if the <em>CURSOR</em> clause does not use the <em>LOOP</em> clause, the DBMS will display the results of the first data in the Customers table. Meanwhile, if you use the <em>LOOP</em> clause, the data displayed is the last data in the Customers table.</p><p>That’s all the discussion about Using VIEW and CURSOR in SQL. I look forward to your suggestions and comments. Thank you 😜 😛 😆.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7a04d741a965" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>