How can a json id and database table id be mapped in ruby on rails and the output of the result be shown on UI. I have a collection of entries in my database say for id, name, url, code, and on UI i have implemented a table whose values are from Json field. I need to fetch data from database for url and code on UI using map concepts in rails.
Example : Json field : [position":"1","name":"Bitcoin","change24":"-2.59 %","currency":"usd","id":"btc"]. My database has url and id, where id is the same value as in json. All thats needed is to map the id in-order to get the corresponding url on UI.