A field surveyor has collected the location of weirs in your catchment using a handheld GPS.  You wish to know the distance upstream to the nearest know salmon spawning site.  Your search will be constrained by the route to source; you are only interested in spawning sites along the main stem.  The spawning sites were mapped in a previous project over several years. You are interested in the most recent spawning sites.

WarningThe following guide is using a fictitious set of points and is in no way representing known weirs/spawning sites!



Processing Task


You have prepared your river network and added the required attribution to the network so you can use the Find nearest Upstream site(s) tool.  How do you know which attributes you need to add to the network so this tool will function? The answer is in the help file, under the usage section. You need to have attributed your river network with Catchment ID, Source ID and Distance to mouth.


You have converted your GPS data into a spatial dataset such as File GeoDatabase point Feature Class. It must be in the same coordinate system as your river network layer and have a numeric ID field. Avoid using shapefiles these are an old data format with limitations.


Data collected by GPS won't be aligned to the network, you need to run the snap sites to network tool. It will be the snapped data you will work with.

Raw GPS weir data


Snap sites tool


Snapped data

Unsnapped GPS Weirs

Snap tool

GPS weir snapped


Spawning sites added to the map and labelled with survey date. This data must be snapped to the network, in the same coordinate system as the river network and have a numeric ID field.

Spawning data


The find nearest upstream site tool is completed as shown below, note the constrain to source ID and return nearest reachable are ticked on. The filter has been set to select sites greater than the earliest date recorded in 2023 which happened to be the 8/2/23, this essentially selects all sites that were recorded in 2023.  Output is written to the Sites GeoDatabase.

Find nearest upstream site


Understanding the output, field names are described here:

Result table

  • Weir 1 nearest upstream spawning site is 866m, this is a site on the same route to source as well as being a site surveyed in 2023.
  • Weir 2 has no site upstream of it on the same route to source, although you can observe a recent survey in a sub-catchment.
  • Weir 3 nearest upstream spawning site is 3437m, this is a site on the same route to source as well as being a site surveyed in 2023.


The above workflow is constraining the search along the route to source so will ignore upstream sites in other sub-catchments. To find any nearest upstream site simply untick constrain to source ID. Finally to find all upstream sites untick return all nearest reachable sites and clear the SQL filter.  These simple but powerful options can have a profound impact on what the tool returns.

Return to top of page