SQL and JSON database - R
Your WEBS_4 is an array with two elements, so there's no ip element in it, which explains why this fails:

dbGetQuery(conexion,"SELECT 
              data-&gt;'results'-&gt;'WEBS'-&gt;'WEBS_4' -&gt;'ip' as test
                          FROM results;")


You need to get the zeroth element of WEBS_4, and then you can get the ip element of that. This works in a simple PostgreSQL test I set up using psql:

SELECT  data-&gt;'results'-&gt;'WEBS'-&gt;'WEBS_4'-&gt;0-&gt;'ip' as test
                          FROM results;
  test   
---------
 "XXXXX"
(1 row)


So I suspect the relevant R syntax will be (untested):

dbGetQuery(conexion,"SELECT 
              data-&gt;'results'-&gt;'WEBS'-&gt;'WEBS_4'-&gt;0-&gt;'ip' as test
                          FROM results;")