foreignID from HubDB return an empty array

I’m working on a customization for mine template trying to integrate HubDB. I’m displaying a table into the frontend and all string’s field works. The only one field with foreignId column (dropdown) doesn’t work and the field return “[]” as seem as an empty array.

I’m checking mine code but it seem right.
Someone can help me?

<div class="certificate-card">
 <h1>{{ dynamic_page_hubdb_row.nome }} {{ dynamic_page_hubdb_row.cognome }}</h1>
 <h2>data rilascio {{ data_di_rilascio }}</h2>
 <h2>data scadenza {{ data_di_scadenza }}</h2>
 <h2>canali 
 {% for foreign_row in canali_di_distribuzione %}
 * {{ foreign_row }}
 the name for foreign row {{ foreign_row.hs_id }} is {{ foreign_row.name }}
 {% endfor %}
 </h2>
 </div>

The field is named “canali_di_distribuzione” and i’m trying to loop this field but seem it’s empty.

Hey @AlessandAlessio

It seems like the reference to the current row is missing when trying to get the value in the foreign table.

Have you tried this?

<div class="certificate-card">
 <h1>{{ dynamic_page_hubdb_row.nome }} {{ dynamic_page_hubdb_row.cognome }}</h1>
 <h2>data rilascio {{ data_di_rilascio }}</h2>
 <h2>data scadenza {{ data_di_scadenza }}</h2>
 <h2>canali 
 {% for foreign_row in dynamic_page_hubdb_row.canali_di_distribuzione %}
 * {{ foreign_row }}
 the name for foreign row {{ foreign_row.hs_id }} is {{ foreign_row.name }}
 {% endfor %}
 </h2>
 </div>

Essentially, add “dynamic_page_hubdb_row” before “canali_di_distribuzione” to make it be “dynamic_page_hubdb_row.canali_di_distribuzione”.