Help

Vue.js - Retrieving info from a record

Topic Labels: API
3623 1
cancel
Showing results for 
Search instead for 
Did you mean: 
Ana_Anderson
4 - Data Explorer
4 - Data Explorer

Hi there, I’m a bit of a frankencoder - I learn as I copy and tweak - so I’m just following the directions here.

I’m attempting to show just the Name of a linked record, but it’s coming out to look like this: [ “recfJJrXBhwg8oyl9” ]

And any Lookup field turns out like so: [“data here”]

So I assume I need to first retrieve the ID of the linked record so it shows the field I want related to that record, but not sure how to go about coding it out.

My sloppy guesswork is this in the HTML:
Partner:{{ item['id']['Partner']['fields']['Name'] }}

Here’s the full JSFiddle

1 Reply 1
Giovanni_Briggs
6 - Interface Innovator
6 - Interface Innovator

So I assume I need to first retrieve the ID of the linked record so it shows the field I want related to that record, but not sure how to go about coding it out.

Correct. Looking at your JSFiddle, it looks like you are pulling information from your Character table. If that table has linked records, and you want to get the information out of those linked records, you will have to do subsequent GET calls using the linked table and record_id to get the information you want.

The other option is to add a “Lookup” field to your Character table. The Lookup field allows you to add columns from linked records into your table, and the API will return Lookup fields when you make a GET request. This way, when you lookup the rows in your Character table, you’ll have the necessary information from linked fields right in the response and don’t need to do another set of lookups. https://guide.airtable.com/linking-tables/#lookups