question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Join Reorder in Spatial Join

See original GitHub issue

Problem: In broadcast mode, the spatial join optimizer doesn’t reorder join order for performance.

e.g,

select area_name, count(*) 
from sfmap join trips on st_contains(sfmap.geofence, trips.dropoff_point)
group by 1 order by 2 DESC

spatial join will put the larger table trips on the build side.

This might be able to optimize based on parameters of st_contains function. e.g, st_contains(A, B) does it imply the dimension of A is less than dimension of B? I cannot speak for all, but it is true for 90% of our user cases.

@mbasmanova what do you think?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
findepicommented, Jan 12, 2019

What about making it cost- (or at least stats-) -based decision?

0reactions
stale[bot]commented, Jan 18, 2021

This issue has been automatically marked as stale because it has not had any activity in the last 2 years. If you feel that this issue is important, just comment and the stale tag will be removed; otherwise it will be closed in 7 days. This is an attempt to ensure that our open issues remain valuable and relevant so that we can keep track of what needs to be done and prioritize the right things.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Spatial Join (Analysis)—ArcGIS Pro | Documentation
A spatial join matches rows from the Join Features values to the Target ... To change the field order, select a field name...
Read more >
Sorting output fields in a spatial join? - Esri Community
I'm spatially joining 2 features from a layer to another polygon later. How can I sort the joined attributes numerically/alphabetically?
Read more >
Spatial joining one to one when join features must be unique ...
spatial join on just the one selected feature, then append the results each time (or merge all the results at the end).
Read more >
Spatial Join Techniques ∗
Abstract. A variety of techniques for performing a spatial join are presented. Rather than just summarize the literature, this in-depth survey and analysis ......
Read more >
ArcGIS Pro Spatial Join or Relate? - YouTube
Video #105In this video I:- Use a Spatial Join to add a column from a polygon layer (postcodes) to a point layer (pubs)-...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found