I have two tables with matching column, both of integer types. Let if i want to store multiple id's in second table. the best way i know is json.
Now problem is how to match a integer from one table and json from another table.
example
Tables Countries and another is tours
countries column = id, name (integer) Tours column = id,countries_ids (json), name
I want a join on the basis column countries.id = tours.countries_ids
store multiple id's in second table. the best way i know is json.? That is your problem. Don't store multiple id's in 1 row as json. Each id should be in a separate row. Then it is very simple to join the 2 tables.