How do I view Foreign Keys as their names instead of their ID?

How do I view Foreign Keys as their names instead of their ID?

Hello again.

I would like to be able when I insert data in a table which has a foreign key to show me the data of another column instead of typing it’s id

For example a Person can speak many languages: English, Spanish, German, Japanese, Greek

So I have created these tables:
People, Languages, PersonSpeaks

and because I don’t know yet how I can make this connection between my Front-End and Back-End or how I can do this with Sequelize + Express.JS I’m using MySQL Workbench, Excel and Visual Studio Code Extensions for connecting to my Database

Here is an SQL Fiddle with my Tables, Insert Data and a Select Statement
User & Languages

As you can see I can Insert Data just fine if I remember the IDs but I cannot remember the IDs for 100 people and 100 languages.

And what I would like is similar to this

Can someone point me to the right direction how I could I achieve this with REST Api?

Do I create a table where I will get the data with JSON and then post it to a certain URL?


You don’t need to remember the ids if you query by a unique field on the table.

If we assume the and people.fullname are unique, then we could insert into the personspeaks:

insert into personspeaks (peopleid, languageid) values (
(select id from languages where name = ‘a-language’),
(select id from people where fullname = ‘John Doe’)

Now, for the REST API, it’s a little too long to explain how to build it, so I would suggest you to [take the freecodecamp APIs and micro services] ( course.