0

I want to make a join between the table people and vehicles, which both share this value,

in the people table the field is vehicles

["https://swapi.dev/api/vehicles/14/","https://swapi.dev/api/vehicles/30/"]

and in the vehicles table the field is url

https://swapi.dev/api/vehicles/14/

As you can see in the first one there is like a list of strings, how could I do the query? is sqlite

I tried this, but does not work

SELECT *
FROM people
INNER JOIN vehicles
ON people.vehicles = vehicles.url 

you can see the endpoints here: https://swapi.dev/api/people/ https://swapi.dev/api/vehicles/

also i see this post How to join array of strings? but it didn't solve my problem

Dubbain
  • 73
  • 1
  • 8

1 Answers1

0
SELECT *
FROM people
INNER JOIN vehicles
ON people.vehicles like '%'+ vehicles.url  +'%'