Skip to main content
Solved

Table Where clause in PostGIS. How do I sort out all objects that are within an polygon?

  • February 26, 2018
  • 4 replies
  • 21 views

Forum|alt.badge.img+1

Hey!

I have a problem with my PostGIS database. Trying to get it much more efficient. It contains information from several counties, which means I read a lot of unnecessary information that I do not need and the computer is giving up.

Something similar "Fastkart.ak = '2085' and all information within 2085 from Fastkart.by" is what I need to do. But can’t figure out how. I’ve tried many hours to write clause under feature type and also by using sqlexecutor.

Figure 1 shows all tables in the database. Often when I am going to read information from my municipality, it must read all the municipalities' buildings eg which makes it very big amounts. Of course, you can drive a clipper directly after the base but would be better if I could get the data base to read no information other than it by 2085.

Anyone know if it’s possible to write "Where clause" directly in the database when you do not have matching information I attribute table?

(That would be the best option)

Option 2 belongs to the pictures 2,3,4

The pictures 3.1.3.2 show the attribute tables that I am interested in. They have no attribute matching each other and therefore I need to do intersect, within, spatial join or similar.

Stored fixed map.ak contains the polygon that shows the surface of my municipality. That has reached 2085. Fastkart.by contains all buildings.

Would you like to write a "Where clause" where I get all the information from fastkart.by that is located within fastkart.ak2085.

In Figure 4 you will see my last attempt to do this with the sql executor.

Can’t load workbench with database for privacy reasons.

Best answer by david_r

Try the FeatureReader rather than the SQLExecutor. You can send the municipality polygon to the FeatureReader and it will automatically filter the features using the geometry.

View original
Did this help you find an answer to your question?

4 replies

david_r
Celebrity
  • Best Answer
  • February 26, 2018

Try the FeatureReader rather than the SQLExecutor. You can send the municipality polygon to the FeatureReader and it will automatically filter the features using the geometry.


takashi
Evangelist
  • February 26, 2018

Hi @flugan87, the @Value function should starts with uppercase V.

The SQLExcutor might work after correcting the function name, but I think using the FeatureReader (set 'Contain' to the Spatial Filter parameter) would be easier in this case.


takashi
Evangelist
  • February 26, 2018
takashi wrote:

Hi @flugan87, the @Value function should starts with uppercase V.

The SQLExcutor might work after correcting the function name, but I think using the FeatureReader (set 'Contain' to the Spatial Filter parameter) would be easier in this case.

oops, duplicate answer.

 

 


Forum|alt.badge.img+1
  • Author
  • February 27, 2018
david_r wrote:

Try the FeatureReader rather than the SQLExecutor. You can send the municipality polygon to the FeatureReader and it will automatically filter the features using the geometry.

Thank you!!

 

Still a newbie at this and have alot to learn.

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings