<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Displaying recent entries from chlid HubDB in CMS Development</title>
    <link>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/471113#M24320</link>
    <description>&lt;P&gt;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/103660"&gt;@piersg&lt;/a&gt; , &lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/91608"&gt;@alyssamwilie&lt;/a&gt; -- see anything funky here?&lt;/P&gt;</description>
    <pubDate>Mon, 02 Aug 2021 20:13:55 GMT</pubDate>
    <dc:creator>dennisedson</dc:creator>
    <dc:date>2021-08-02T20:13:55Z</dc:date>
    <item>
      <title>Displaying recent entries from chlid HubDB</title>
      <link>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/470850#M24314</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have a parent database, that has 3/4 child DB's sitting underneath it. What I need is the page to pull in the 5 most recent entries and display them in a list.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm using the following code, but it doesn't appear to be working.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The code is meant to create an array, pulling in all entries across the child DBs, sort by date created, and then loop through 5 times and spit out the 5 latest entries.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What am I missing?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;			{% set childCombineArr = [] %}
			{% for row in hubdb_table_rows(dynamic_page_hubdb_table_id, queryparam) %}
			{% if row.hs_child_table_id %}
				{% set child_table = hubdb_table_rows(row.hs_child_table_id) %}
				{% for row in child_table %}
					{% set timeAdded = row.createdAt %}
					{% do childCombineArr.append({'timeAdded': timeAdded, 'row': row}) %}
				{% endfor %}
			{% endif %}
		{% endfor %}
		{% for item in childCombineArr|sort(True, False, 'timeAdded') %}
			{% if loop.index &amp;lt;= 5 %}
				{% set row = item.row %}
				{{row.name}}
			{% endif %}
		{% endfor %}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 15:00:12 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/470850#M24314</guid>
      <dc:creator>pm8rsh88</dc:creator>
      <dc:date>2021-08-02T15:00:12Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying recent entries from chlid HubDB</title>
      <link>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/471113#M24320</link>
      <description>&lt;P&gt;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/103660"&gt;@piersg&lt;/a&gt; , &lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/91608"&gt;@alyssamwilie&lt;/a&gt; -- see anything funky here?&lt;/P&gt;</description>
      <pubDate>Mon, 02 Aug 2021 20:13:55 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/471113#M24320</guid>
      <dc:creator>dennisedson</dc:creator>
      <dc:date>2021-08-02T20:13:55Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying recent entries from chlid HubDB</title>
      <link>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/471415#M24330</link>
      <description>&lt;P&gt;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/13982"&gt;@dennisedson&lt;/a&gt;&amp;nbsp;I'm pretty sure this is based off my code which I've provided on the forum before haha.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/90514"&gt;@pm8rsh88&lt;/a&gt;&amp;nbsp;You want &lt;CODE&gt;row.hs_created_at&lt;/CODE&gt; not &lt;CODE&gt;row.createdAt&lt;/CODE&gt;&amp;nbsp;so&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{% set timeAdded = row.hs_created_at %}&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 03 Aug 2021 10:04:47 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/471415#M24330</guid>
      <dc:creator>piersg</dc:creator>
      <dc:date>2021-08-03T10:04:47Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying recent entries from chlid HubDB</title>
      <link>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/471772#M24340</link>
      <description>&lt;P&gt;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/103660"&gt;@piersg&lt;/a&gt;&amp;nbsp; we need a code collection area for the Community &lt;span class="lia-unicode-emoji" title=":eyes:"&gt;👀&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Aug 2021 18:12:20 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/471772#M24340</guid>
      <dc:creator>dennisedson</dc:creator>
      <dc:date>2021-08-03T18:12:20Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying recent entries from chlid HubDB</title>
      <link>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/472232#M24354</link>
      <description>&lt;P&gt;I just checked and yes it is your code. Thank you for supplying it originally.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you! That's fixed the issue. Now I just need to style it accordingly.&lt;/P&gt;</description>
      <pubDate>Wed, 04 Aug 2021 08:34:04 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/Displaying-recent-entries-from-chlid-HubDB/m-p/472232#M24354</guid>
      <dc:creator>pm8rsh88</dc:creator>
      <dc:date>2021-08-04T08:34:04Z</dc:date>
    </item>
  </channel>
</rss>

