<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>article Parsing: JSON Array (Homogeneous Objects) in Member Articles</title>
    <link>https://community.qlik.com/t5/Member-Articles/Parsing-JSON-Array-Homogeneous-Objects/ta-p/2535153</link>
    <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="JSONArraysImage.png" style="width: 496px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184704i7FC93B4C7377A3BC/image-size/large?v=v2&amp;amp;px=999" role="button" title="JSONArraysImage.png" alt="JSONArraysImage.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The image depicts what is called a &lt;STRONG&gt;&lt;FONT color="#993300"&gt;JSON Array&lt;/FONT&gt;&lt;/STRONG&gt; and to be precise its a JSON Array of Homogeneous Objects. I'm sure you are no greenhorn at this point in my series on parsing JSON. If I said tell me the name &lt;STRONG&gt;&lt;FONT color="#993300"&gt;who is the owner of the third saloon&lt;/FONT&gt;&lt;/STRONG&gt; in our town, I'm sure you would immediately reply "&lt;FONT color="#993300"&gt;&lt;STRONG&gt;Miss Ada&lt;/STRONG&gt;&lt;/FONT&gt;."&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This post is going to focus on how you came to your answer. Guess what function Qlik Sense provides that will allow you to parse that answer out of this unstructured textual array just like you were able to do with your human mind?&lt;/P&gt;
&lt;H2 id="toc-hId--411526296"&gt;JsonGet()&lt;/H2&gt;
&lt;P&gt;If you guessed it was the same JsonGet() function covered in the previous posts on&amp;nbsp;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Flat-JSON-Field-Value-Pairs/ta-p/2535096" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Flat JSON - Field Value Pairs&lt;/A&gt;&amp;nbsp;and &lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Nested-JSON-Objects/ta-p/2535112" target="_blank" rel="noopener"&gt;Parsing: Nested JSON Objects&lt;/A&gt; you are 100% correct.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The how is where it gets interesting. In the post Parsing: Nested JSON Objects, I brought up the concept that we needed to qualify the path to our field:value pair and we worked through how accessing the name field for an entity called sheriff was accomplished by doing this:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Dalton_Ruer_0-1762207773013.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184705iE1BD923E75870EA4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Dalton_Ruer_0-1762207773013.png" alt="Dalton_Ruer_0-1762207773013.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;I told you that the notation was essentially &lt;STRONG&gt;&lt;FONT color="#993300"&gt;/entity/field&lt;/FONT&gt;&lt;/STRONG&gt;. But you somehow managed to astound me with your ability to parse the opening image and provide the answer to my question about the third saloon. You were able to answer because you automatically, in your mind, altered that notation to be something like /entity/&lt;STRONG&gt;&lt;FONT color="#993300"&gt;INDEX&lt;/FONT&gt;&lt;/STRONG&gt;/field.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;The essential part of this post is the fact that the &lt;FONT color="#993300"&gt;INDEX&lt;/FONT&gt; value starts at an &lt;FONT color="#993300"&gt;offset&lt;/FONT&gt; of &lt;FONT color="#993300"&gt;0&lt;/FONT&gt;. Meaning the &lt;FONT color="#993300"&gt;first value&lt;/FONT&gt; has an index of &lt;FONT color="#993300"&gt;0&lt;/FONT&gt;.&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Assume that the JSON structure from the image at the start of the post is inside a field called Array that is in a table called JSON_Array. The following code would pull out values from the array. Notice that we pull the name, owner and capacity field values for the first saloon. We only pull the name for the second saloon. The last line simply pulls the entire JSON block, the "row" itself for the final saloon in our array. Maybe it will deal with parsing it later. It's entirely possible that I purposely did that in this basic post to prepare for a much much deeper post in the future where that is in fact what I do. I pull out the block and deal with it in a different part of the code.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Dalton_Ruer_0-1762208076592.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184706iA4961029E01EAC66/image-size/large?v=v2&amp;amp;px=999" role="button" title="Dalton_Ruer_0-1762208076592.png" alt="Dalton_Ruer_0-1762208076592.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;H2&gt;Practice&lt;/H2&gt;
&lt;P&gt;&lt;SPAN&gt;If you are anything like me you don't like to assume anything, and you are a visual or experiential learner. So, go ahead and download the attached&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;&lt;FONT color="#993300"&gt;WildDataFrontier.qvf&lt;/FONT&gt;&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;that is attached, upload it to your environment and open the load script.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Section3.png" style="width: 285px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184707i532E436245D5B8F0/image-size/large?v=v2&amp;amp;px=999" role="button" title="Section3.png" alt="Section3.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;{ Notice there are multiple sections. Each of them will pertain to a separate article and for this article the section named "&lt;STRONG&gt;&lt;FONT color="#993300"&gt;3 - JSON Array: Homogeneous Objects&lt;/FONT&gt;&lt;/STRONG&gt;" is the one you want to have at the top of your script for this post. }&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="JSONArrayCodeImage.png" style="width: 785px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184708i48BED76594FF97FE/image-size/large?v=v2&amp;amp;px=999" role="button" title="JSONArrayCodeImage.png" alt="JSONArrayCodeImage.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Each section will begin with a common pattern. I will show you the prettified version of the JSON structure. Meaning it's indented, and thus easy to read. Then I will remove the line feeds so that the JSON structure being covered is a single line that we deal with as a single string for transformation within Qlik Sense. That single text/block is what API's will return or what you will read out of textual fields that contain JSON blocks from RDMBS systems. In the other articles it was easy for me to simply create an inline table that contained that JSON Block. But for an array we have a special issue to deal with ... those brackets the define the beginning and end of the array "[" "]"&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Those 2 characters are special and define the beginning and end of our inline statement and thus they cause a problem. Notice that I've simply duplicated the characters [[ and ]] in my line of code, so that the inline table reads it in, and then I do a preceding load to pull the duplicate brackets right back out.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;H2&gt;&lt;SPAN&gt;Preview&lt;/SPAN&gt;&lt;/H2&gt;
&lt;P&gt;&lt;SPAN&gt;Before you worry about making any changes, simply load the script as is and go to the Preview window and see the JSON_Array table. You will then see that our Array field is formatted as needed to be a proper JSON Array.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Dalton_Ruer_1-1762209002119.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184709i2250034CD4F79D9D/image-size/large?v=v2&amp;amp;px=999" role="button" title="Dalton_Ruer_1-1762209002119.png" alt="Dalton_Ruer_1-1762209002119.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;H2&gt;Iterative&lt;/H2&gt;
&lt;P&gt;When I began the article I asked you to focus on the third saloon. Then I showed you the code needed to parse out and get the same response from the code that you were able to do mentally. 3 entries fit my example case for this post because ... I needed to parse out the array 3 different ways. I wanted all values for a "row", only 1 value for a "row" and just the JSON for the final "row."&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But I don't want to leave you hanging there. Some rascally gunslinger is bound to head into your town with 5 rows. Or 10 rows. Or 20 rows. The last thing I want you to do is sit there and hand code a hard coded limit and then tell the good folks in your town that as Data Sheriff you will happily give them insights from the first 20 values. They just might run you out of town.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Never fear my friend, Qlik Sense provides a fantastic function call that will actually iterate through as many rows as needed. The function is called &lt;A href="https://help.qlik.com/en-US/sense/May2025/Subsystems/Hub/Content/Sense_Hub/Scripting/CounterFunctions/IterNo.htm" target="_blank" rel="noopener"&gt;IterNo()&lt;/A&gt; and as the help makes really clear, the only useful purpose for the &lt;FONT color="#993300"&gt;&lt;STRONG&gt;IterNo()&lt;/STRONG&gt;&lt;/FONT&gt; function is when used with a &lt;STRONG&gt;&lt;FONT color="#993300"&gt;While&lt;/FONT&gt; &lt;/STRONG&gt;condition. In other words ... you need a way to ensure we end the recursion.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So here is how we can utilize it to parse our JSON Array of Homogeneous Objects. Rather than just reading the resident JSON_Array like we did above when hardcoding the parsing, we simply take advantage of the IterNo() function and then combine it with another Qlik Sense function called IsJson().&amp;nbsp;&lt;/P&gt;
&lt;P class="lia-indent-padding-left-30px"&gt;&lt;STRONG&gt;&lt;EM&gt;Resident JSON_Array&lt;/EM&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;EM&gt;WHILE IsJson(JsonGet(Array, '/saloons/' &amp;amp; (IterNo()-1)));&lt;/EM&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;The IterNo() function will start at 1 and then keep iterating, until you tell it to stop. Easy breasy.&lt;/P&gt;
&lt;P&gt;The IsJson() function will say "Yep you have properly a properly formatted JSON structure" or "Sorry partner you drew a bad hand."&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thus ... as the IterNo() function iterates through we will be handling the following:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;WHILE IsJson(JsonGet(Array, '/saloons/0')));&lt;/LI&gt;
&lt;LI&gt;WHILE IsJson(JsonGet(Array, '/saloons/1')));&lt;/LI&gt;
&lt;LI&gt;WHILE IsJson(JsonGet(Array, '/saloons/2')));&lt;/LI&gt;
&lt;LI&gt;WHILE IsJson(JsonGet(Array, '/saloons/3')));&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;The first 3 iterations will succeed, but the 4'th iteration will return nothing and thus end our while loop. As you will see in the script in the WildDataFrontier application, we can then simply refer to the iteration number (will remain constant for the row being processed) and pull out our values for every row that is returned in the array. Whether it be 1, 10, 20, 100 or more.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="IterationCodeImage.png" style="width: 648px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184711i16A71B1CDBCBB1A3/image-size/large?v=v2&amp;amp;px=999" role="button" title="IterationCodeImage.png" alt="IterationCodeImage.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Thus when we preview the flat/hardcoded method the results are usable&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="PreviewFlat.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184712i3F26C424DD34F474/image-size/large?v=v2&amp;amp;px=999" role="button" title="PreviewFlat.png" alt="PreviewFlat.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But when we preview this iterative approach the results are usable today, tomorrow and next year. So, you can remain as the Data Sheriff.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="PreviewIterative.png" style="width: 711px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184713i06FC56DFFEFD58B7/image-size/large?v=v2&amp;amp;px=999" role="button" title="PreviewIterative.png" alt="PreviewIterative.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;H2 id="toc-hId-1628650518"&gt;&lt;STRONG&gt;&lt;FONT color="#008000"&gt;Big Picture&lt;/FONT&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/H2&gt;
&lt;P&gt;This post is part of a series aimed at ensuring you have the tools needed to Tame with Wild West Data Frontier, I mean Tame the Wild JSON Data Frontier you may be facing.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Posts:&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://%20https/community.qlik.com/t5/Member-Articles/Parsing-Flat-JSON-Field-Value-Pairs/ta-p/2535096" target="_blank" rel="nofollow noopener noreferrer" aria-describedby="audioeye_new_window_message"&gt;Taming the Wild JSON Data Frontier&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="http://%20https/community.qlik.com/t5/Member-Articles/Parsing-Flat-JSON-Field-Value-Pairs/ta-p/2535096" target="_blank" rel="nofollow noopener noreferrer" aria-describedby="audioeye_new_window_message"&gt;Parsing: Flat JSON - Field Value Pairs&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Nested-JSON-Objects/ta-p/2535112" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Nested JSON Objects&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-JSON-Array-Homogeneous-Objects/ta-p/2535153" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: JSON Array (Homogeneous Objects) &amp;lt;--- You are here&lt;/A&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Heterogeneous-Mixed-JSON-Objects-Fixed-Manner/ta-p/2535212" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Heterogeneous (Mixed) JSON Objects Fixed Manner&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Heterogeneous-Mixed-JSON-Objects-Flexible-Manner/ta-p/2535225" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Heterogeneous (Mixed) JSON Objects Flexible Manner&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Heterogeneous-Mixed-JSON-Arrays/ta-p/2535281" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Heterogeneous (Mixed) JSON Arrays&lt;/A&gt;&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 04 Nov 2025 17:37:45 GMT</pubDate>
    <dc:creator>Dalton_Ruer</dc:creator>
    <dc:date>2025-11-04T17:37:45Z</dc:date>
    <item>
      <title>Parsing: JSON Array (Homogeneous Objects)</title>
      <link>https://community.qlik.com/t5/Member-Articles/Parsing-JSON-Array-Homogeneous-Objects/ta-p/2535153</link>
      <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="JSONArraysImage.png" style="width: 496px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184704i7FC93B4C7377A3BC/image-size/large?v=v2&amp;amp;px=999" role="button" title="JSONArraysImage.png" alt="JSONArraysImage.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The image depicts what is called a &lt;STRONG&gt;&lt;FONT color="#993300"&gt;JSON Array&lt;/FONT&gt;&lt;/STRONG&gt; and to be precise its a JSON Array of Homogeneous Objects. I'm sure you are no greenhorn at this point in my series on parsing JSON. If I said tell me the name &lt;STRONG&gt;&lt;FONT color="#993300"&gt;who is the owner of the third saloon&lt;/FONT&gt;&lt;/STRONG&gt; in our town, I'm sure you would immediately reply "&lt;FONT color="#993300"&gt;&lt;STRONG&gt;Miss Ada&lt;/STRONG&gt;&lt;/FONT&gt;."&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This post is going to focus on how you came to your answer. Guess what function Qlik Sense provides that will allow you to parse that answer out of this unstructured textual array just like you were able to do with your human mind?&lt;/P&gt;
&lt;H2 id="toc-hId--411526296"&gt;JsonGet()&lt;/H2&gt;
&lt;P&gt;If you guessed it was the same JsonGet() function covered in the previous posts on&amp;nbsp;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Flat-JSON-Field-Value-Pairs/ta-p/2535096" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Flat JSON - Field Value Pairs&lt;/A&gt;&amp;nbsp;and &lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Nested-JSON-Objects/ta-p/2535112" target="_blank" rel="noopener"&gt;Parsing: Nested JSON Objects&lt;/A&gt; you are 100% correct.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The how is where it gets interesting. In the post Parsing: Nested JSON Objects, I brought up the concept that we needed to qualify the path to our field:value pair and we worked through how accessing the name field for an entity called sheriff was accomplished by doing this:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Dalton_Ruer_0-1762207773013.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184705iE1BD923E75870EA4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Dalton_Ruer_0-1762207773013.png" alt="Dalton_Ruer_0-1762207773013.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;I told you that the notation was essentially &lt;STRONG&gt;&lt;FONT color="#993300"&gt;/entity/field&lt;/FONT&gt;&lt;/STRONG&gt;. But you somehow managed to astound me with your ability to parse the opening image and provide the answer to my question about the third saloon. You were able to answer because you automatically, in your mind, altered that notation to be something like /entity/&lt;STRONG&gt;&lt;FONT color="#993300"&gt;INDEX&lt;/FONT&gt;&lt;/STRONG&gt;/field.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;The essential part of this post is the fact that the &lt;FONT color="#993300"&gt;INDEX&lt;/FONT&gt; value starts at an &lt;FONT color="#993300"&gt;offset&lt;/FONT&gt; of &lt;FONT color="#993300"&gt;0&lt;/FONT&gt;. Meaning the &lt;FONT color="#993300"&gt;first value&lt;/FONT&gt; has an index of &lt;FONT color="#993300"&gt;0&lt;/FONT&gt;.&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Assume that the JSON structure from the image at the start of the post is inside a field called Array that is in a table called JSON_Array. The following code would pull out values from the array. Notice that we pull the name, owner and capacity field values for the first saloon. We only pull the name for the second saloon. The last line simply pulls the entire JSON block, the "row" itself for the final saloon in our array. Maybe it will deal with parsing it later. It's entirely possible that I purposely did that in this basic post to prepare for a much much deeper post in the future where that is in fact what I do. I pull out the block and deal with it in a different part of the code.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Dalton_Ruer_0-1762208076592.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184706iA4961029E01EAC66/image-size/large?v=v2&amp;amp;px=999" role="button" title="Dalton_Ruer_0-1762208076592.png" alt="Dalton_Ruer_0-1762208076592.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;H2&gt;Practice&lt;/H2&gt;
&lt;P&gt;&lt;SPAN&gt;If you are anything like me you don't like to assume anything, and you are a visual or experiential learner. So, go ahead and download the attached&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;&lt;FONT color="#993300"&gt;WildDataFrontier.qvf&lt;/FONT&gt;&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;that is attached, upload it to your environment and open the load script.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Section3.png" style="width: 285px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184707i532E436245D5B8F0/image-size/large?v=v2&amp;amp;px=999" role="button" title="Section3.png" alt="Section3.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;{ Notice there are multiple sections. Each of them will pertain to a separate article and for this article the section named "&lt;STRONG&gt;&lt;FONT color="#993300"&gt;3 - JSON Array: Homogeneous Objects&lt;/FONT&gt;&lt;/STRONG&gt;" is the one you want to have at the top of your script for this post. }&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="JSONArrayCodeImage.png" style="width: 785px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184708i48BED76594FF97FE/image-size/large?v=v2&amp;amp;px=999" role="button" title="JSONArrayCodeImage.png" alt="JSONArrayCodeImage.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Each section will begin with a common pattern. I will show you the prettified version of the JSON structure. Meaning it's indented, and thus easy to read. Then I will remove the line feeds so that the JSON structure being covered is a single line that we deal with as a single string for transformation within Qlik Sense. That single text/block is what API's will return or what you will read out of textual fields that contain JSON blocks from RDMBS systems. In the other articles it was easy for me to simply create an inline table that contained that JSON Block. But for an array we have a special issue to deal with ... those brackets the define the beginning and end of the array "[" "]"&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Those 2 characters are special and define the beginning and end of our inline statement and thus they cause a problem. Notice that I've simply duplicated the characters [[ and ]] in my line of code, so that the inline table reads it in, and then I do a preceding load to pull the duplicate brackets right back out.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;H2&gt;&lt;SPAN&gt;Preview&lt;/SPAN&gt;&lt;/H2&gt;
&lt;P&gt;&lt;SPAN&gt;Before you worry about making any changes, simply load the script as is and go to the Preview window and see the JSON_Array table. You will then see that our Array field is formatted as needed to be a proper JSON Array.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Dalton_Ruer_1-1762209002119.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184709i2250034CD4F79D9D/image-size/large?v=v2&amp;amp;px=999" role="button" title="Dalton_Ruer_1-1762209002119.png" alt="Dalton_Ruer_1-1762209002119.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;H2&gt;Iterative&lt;/H2&gt;
&lt;P&gt;When I began the article I asked you to focus on the third saloon. Then I showed you the code needed to parse out and get the same response from the code that you were able to do mentally. 3 entries fit my example case for this post because ... I needed to parse out the array 3 different ways. I wanted all values for a "row", only 1 value for a "row" and just the JSON for the final "row."&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But I don't want to leave you hanging there. Some rascally gunslinger is bound to head into your town with 5 rows. Or 10 rows. Or 20 rows. The last thing I want you to do is sit there and hand code a hard coded limit and then tell the good folks in your town that as Data Sheriff you will happily give them insights from the first 20 values. They just might run you out of town.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Never fear my friend, Qlik Sense provides a fantastic function call that will actually iterate through as many rows as needed. The function is called &lt;A href="https://help.qlik.com/en-US/sense/May2025/Subsystems/Hub/Content/Sense_Hub/Scripting/CounterFunctions/IterNo.htm" target="_blank" rel="noopener"&gt;IterNo()&lt;/A&gt; and as the help makes really clear, the only useful purpose for the &lt;FONT color="#993300"&gt;&lt;STRONG&gt;IterNo()&lt;/STRONG&gt;&lt;/FONT&gt; function is when used with a &lt;STRONG&gt;&lt;FONT color="#993300"&gt;While&lt;/FONT&gt; &lt;/STRONG&gt;condition. In other words ... you need a way to ensure we end the recursion.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So here is how we can utilize it to parse our JSON Array of Homogeneous Objects. Rather than just reading the resident JSON_Array like we did above when hardcoding the parsing, we simply take advantage of the IterNo() function and then combine it with another Qlik Sense function called IsJson().&amp;nbsp;&lt;/P&gt;
&lt;P class="lia-indent-padding-left-30px"&gt;&lt;STRONG&gt;&lt;EM&gt;Resident JSON_Array&lt;/EM&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;EM&gt;WHILE IsJson(JsonGet(Array, '/saloons/' &amp;amp; (IterNo()-1)));&lt;/EM&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;The IterNo() function will start at 1 and then keep iterating, until you tell it to stop. Easy breasy.&lt;/P&gt;
&lt;P&gt;The IsJson() function will say "Yep you have properly a properly formatted JSON structure" or "Sorry partner you drew a bad hand."&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thus ... as the IterNo() function iterates through we will be handling the following:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;WHILE IsJson(JsonGet(Array, '/saloons/0')));&lt;/LI&gt;
&lt;LI&gt;WHILE IsJson(JsonGet(Array, '/saloons/1')));&lt;/LI&gt;
&lt;LI&gt;WHILE IsJson(JsonGet(Array, '/saloons/2')));&lt;/LI&gt;
&lt;LI&gt;WHILE IsJson(JsonGet(Array, '/saloons/3')));&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;The first 3 iterations will succeed, but the 4'th iteration will return nothing and thus end our while loop. As you will see in the script in the WildDataFrontier application, we can then simply refer to the iteration number (will remain constant for the row being processed) and pull out our values for every row that is returned in the array. Whether it be 1, 10, 20, 100 or more.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="IterationCodeImage.png" style="width: 648px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184711i16A71B1CDBCBB1A3/image-size/large?v=v2&amp;amp;px=999" role="button" title="IterationCodeImage.png" alt="IterationCodeImage.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Thus when we preview the flat/hardcoded method the results are usable&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="PreviewFlat.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184712i3F26C424DD34F474/image-size/large?v=v2&amp;amp;px=999" role="button" title="PreviewFlat.png" alt="PreviewFlat.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But when we preview this iterative approach the results are usable today, tomorrow and next year. So, you can remain as the Data Sheriff.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="PreviewIterative.png" style="width: 711px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/184713i06FC56DFFEFD58B7/image-size/large?v=v2&amp;amp;px=999" role="button" title="PreviewIterative.png" alt="PreviewIterative.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;H2 id="toc-hId-1628650518"&gt;&lt;STRONG&gt;&lt;FONT color="#008000"&gt;Big Picture&lt;/FONT&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/H2&gt;
&lt;P&gt;This post is part of a series aimed at ensuring you have the tools needed to Tame with Wild West Data Frontier, I mean Tame the Wild JSON Data Frontier you may be facing.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Posts:&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://%20https/community.qlik.com/t5/Member-Articles/Parsing-Flat-JSON-Field-Value-Pairs/ta-p/2535096" target="_blank" rel="nofollow noopener noreferrer" aria-describedby="audioeye_new_window_message"&gt;Taming the Wild JSON Data Frontier&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="http://%20https/community.qlik.com/t5/Member-Articles/Parsing-Flat-JSON-Field-Value-Pairs/ta-p/2535096" target="_blank" rel="nofollow noopener noreferrer" aria-describedby="audioeye_new_window_message"&gt;Parsing: Flat JSON - Field Value Pairs&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Nested-JSON-Objects/ta-p/2535112" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Nested JSON Objects&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-JSON-Array-Homogeneous-Objects/ta-p/2535153" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: JSON Array (Homogeneous Objects) &amp;lt;--- You are here&lt;/A&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Heterogeneous-Mixed-JSON-Objects-Fixed-Manner/ta-p/2535212" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Heterogeneous (Mixed) JSON Objects Fixed Manner&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Heterogeneous-Mixed-JSON-Objects-Flexible-Manner/ta-p/2535225" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Heterogeneous (Mixed) JSON Objects Flexible Manner&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A href="https://community.qlik.com/t5/Member-Articles/Parsing-Heterogeneous-Mixed-JSON-Arrays/ta-p/2535281" target="_blank" rel="noopener" aria-describedby="audioeye_new_window_message"&gt;Parsing: Heterogeneous (Mixed) JSON Arrays&lt;/A&gt;&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Nov 2025 17:37:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Member-Articles/Parsing-JSON-Array-Homogeneous-Objects/ta-p/2535153</guid>
      <dc:creator>Dalton_Ruer</dc:creator>
      <dc:date>2025-11-04T17:37:45Z</dc:date>
    </item>
  </channel>
</rss>

