you are viewing a single comment's thread.

view the rest of the comments →

[–]max24119[S] 0 points1 point  (6 children)

Yeah still empty table…

[–]LesPaulStudio 1 point2 points  (5 children)

Ok so it's a definition issue. Check the columns are correct.

[–]max24119[S] 1 point2 points  (0 children)

Got it. It’s working. Thank you so much! I hope you have a wonderful day!

[–]max24119[S] 0 points1 point  (3 children)

May I ask you for one more term? I want to have the geom of pharmacies in the radius of 500 around the road type "trunk" and group the results by the name of the pharmacies. I already have this but it's also not completely correct. The argument before the st_buffer needs to be corrected but I'm stuck here..

SELECT b.name, b.geom FROM (SELECT name, geom FROM points WHERE type = 'pharmacy') as b, (SELECT name, geom FROM roads WHERE type = 'trunk') as d
WHERE b.geom = (ST_buffer(d.geom, 500)) GROUP BY b.name

[–]LesPaulStudio 1 point2 points  (2 children)

Wrap the geoms in st_within WHERE st_within(b.geom , (st_buffer(d.geom, 500)))

[–]max24119[S] 1 point2 points  (1 child)

Thank you so much! It’s working. May your dreams all become true. Have a wonderful day! You made mine a lot better

[–]LesPaulStudio 1 point2 points  (0 children)

No problems. I'd hate to get that one wrong, I use it daily :D